aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/Updater
diff options
context:
space:
mode:
authorVirtualTam <virtualtam@flibidi.net>2017-08-23 01:08:41 +0200
committerVirtualTam <virtualtam@flibidi.net>2017-08-23 01:08:41 +0200
commit9d7a02afcee3c740712a7c95182d332db0504b7e (patch)
tree3266e3d3bfec6a3ac075084cbec07ba4090c4cd2 /tests/Updater
parentc318096c7a6fb3f6b00bd8c694ab7acb8fbb7cd0 (diff)
parent7c2460c856c1d561b8347316f3045208f9f3d24e (diff)
downloadShaarli-9d7a02afcee3c740712a7c95182d332db0504b7e.tar.gz
Shaarli-9d7a02afcee3c740712a7c95182d332db0504b7e.tar.zst
Shaarli-9d7a02afcee3c740712a7c95182d332db0504b7e.zip
Merge branch 'master' into v0.9
Diffstat (limited to 'tests/Updater')
-rw-r--r--tests/Updater/UpdaterTest.php40
1 files changed, 0 insertions, 40 deletions
diff --git a/tests/Updater/UpdaterTest.php b/tests/Updater/UpdaterTest.php
index 11b6444a..fed175df 100644
--- a/tests/Updater/UpdaterTest.php
+++ b/tests/Updater/UpdaterTest.php
@@ -470,46 +470,6 @@ $GLOBALS[\'privateLinkByDefault\'] = true;';
470 } 470 }
471 471
472 /** 472 /**
473 * Test updateMethodDefaultThemeVintage with the default theme enabled.
474 */
475 public function testSetDefaultThemeToVintage()
476 {
477 $sandboxConf = 'sandbox/config';
478 copy(self::$configFile . '.json.php', $sandboxConf . '.json.php');
479 $this->conf = new ConfigManager($sandboxConf);
480
481 $this->conf->set('resource.theme', 'default');
482 $updater = new Updater([], [], $this->conf, true);
483 $this->assertTrue($updater->updateMethodDefaultThemeVintage());
484 $this->assertEquals('vintage', $this->conf->get('resource.theme'));
485
486 // reload from file
487 $this->conf = new ConfigManager($sandboxConf);
488 $this->assertEquals('vintage', $this->conf->get('resource.theme'));
489 }
490
491 /**
492 * Test updateMethodDefaultThemeVintage with custom theme enabled => nothing to do.
493 */
494 public function testSetDefaultThemeNothingToDo()
495 {
496 $sandboxConf = 'sandbox/config';
497 copy(self::$configFile . '.json.php', $sandboxConf . '.json.php');
498 $this->conf = new ConfigManager($sandboxConf);
499
500 $theme = 'myawesometheme';
501 $this->conf->set('resource.theme', $theme);
502 $this->conf->write(true);
503 $updater = new Updater([], [], $this->conf, true);
504 $this->assertTrue($updater->updateMethodDefaultThemeVintage());
505 $this->assertEquals($theme, $this->conf->get('resource.theme'));
506
507 // reload from file
508 $this->conf = new ConfigManager($sandboxConf);
509 $this->assertEquals($theme, $this->conf->get('resource.theme'));
510 }
511
512 /**
513 * Test updateMethodEscapeMarkdown with markdown plugin enabled 473 * Test updateMethodEscapeMarkdown with markdown plugin enabled
514 * => setting markdown_escape set to false. 474 * => setting markdown_escape set to false.
515 */ 475 */