-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move Customizer controls for Header Brand Component (#641)
* fix: move customizer controls for header brand * fix: editor styles leaking into customizer panels * feat: allow emblem as logo in header * refactor: opening php tag
- Loading branch information
Showing
11 changed files
with
202 additions
and
129 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
<?php | ||
|
||
class BaseControllerTest extends \WP_UnitTestCase | ||
{ | ||
public function testGetLogotypeReturnsString() | ||
{ | ||
$baseController = new \Municipio\Controller\BaseController(); | ||
$this->assertIsString($baseController->getLogotype()); | ||
} | ||
|
||
public function testGetLogotypeReturnsDefaultUrlIfNoOtherFound() | ||
{ | ||
$baseController = new \Municipio\Controller\BaseController(); | ||
$defaultLogotype = $baseController->getDefaultLogotype(); | ||
$this->assertEquals($defaultLogotype, $baseController->getLogotype()); | ||
} | ||
|
||
public function testGetLogotypeReturnsVariantUrlIfSet() | ||
{ | ||
set_theme_mod('logotype_negative', 'bar'); | ||
$baseController = new \Municipio\Controller\BaseController(); | ||
$this->assertEquals('bar', $baseController->getLogotype('negative')); | ||
} | ||
|
||
public function testGetLogotypeDefaultsToStandard() | ||
{ | ||
set_theme_mod('logotype', 'foo'); | ||
$baseController = new \Municipio\Controller\BaseController(); | ||
$this->assertEquals('foo', $baseController->getLogotype()); | ||
} | ||
|
||
public function testGetLogotypeReturnsEmptyIfNotAvailable() | ||
{ | ||
$baseController = new \Municipio\Controller\BaseController(); | ||
$this->assertEquals('', $baseController->getLogotype('foo')); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.