You are here

function sweaverThemeSettings::testScenarioD in Sweaver 7

Same name and namespace in other branches
  1. 6 tests/sweaver.themesettings.test \sweaverThemeSettings::testScenarioD()

Scenario D.

1: Save realize favicon, google logo & Site name off 3: Publish 1 (without logo & realize). 2: Save 1 dummi favicon, jw logo & Site name off 3: Publish 1 (without logo & dummi). 4: Delete 1

File

tests/sweaver.themesettings.test, line 567
Advanced tests for sweaver editor + theme settings.

Class

sweaverThemeSettings
@file Advanced tests for sweaver editor + theme settings.

Code

function testScenarioD() {
  $scenario = 'D';
  $scenario_action = 'Save ' . $scenario;
  $configuration = $this
    ->buildStyleConfiguration($scenario_action, '30', 1, TRUE, 'google.png', 'realize.ico');
  $this
    ->sweaverSaveStyle($scenario_action, $configuration, 1);
  $this
    ->assertLogoFavicon($scenario_action, 1, FALSE, TRUE, FALSE, 'png');
  $this
    ->assertThemeSettings($scenario_action, 1, TRUE, TRUE);
  $scenario_action = 'Publish ' . $scenario;
  $configuration = $this
    ->buildStyleConfiguration($scenario_action, '30', 1, FALSE, 'png', 'ico');
  $this
    ->sweaverPublishStyle($scenario_action, $configuration, 1);
  $this
    ->assertLogoFavicon($scenario_action, 1, FALSE, TRUE, TRUE, 'png');
  $this
    ->assertThemeSettings($scenario_action, 1, FALSE, FALSE, 'png', 'ico');
  $scenario_action = 'Save ' . $scenario;
  $configuration = $this
    ->buildStyleConfiguration($scenario_action, '30000', 1, TRUE, 'jw.gif', 'dummy.ico', TRUE);
  $this
    ->sweaverSaveStyle($scenario_action, $configuration, 1, TRUE, TRUE, FALSE);
  $this
    ->assertLogoFavicon($scenario_action, 1, FALSE, TRUE, FALSE, 'gif', FALSE);
  $this
    ->assertThemeSettings($scenario_action, 1, FALSE, FALSE, 'png', 'ico');
  $scenario_action = 'Publish ' . $scenario;
  $configuration = $this
    ->buildStyleConfiguration($scenario_action, '30000', 1, FALSE, 'gif', 'ico');
  $this
    ->sweaverPublishStyle($scenario_action, $configuration, 1);
  $this
    ->assertLogoFavicon($scenario_action, 1, FALSE, TRUE, TRUE, 'gif');
  $this
    ->assertThemeSettings($scenario_action, 1, FALSE, FALSE, 'gif', 'ico');
  $scenario_action = 'Delete ' . $scenario;
  $configuration = $this
    ->buildStyleConfiguration($scenario_action, 0, 1, FALSE);
  $this
    ->sweaverDeleteStyle($scenario_action, $configuration, 1);
  $this
    ->assertLogoFavicon($scenario_action, 1, TRUE);
}