-
Notifications
You must be signed in to change notification settings - Fork 798
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Calypsoify: Add test to fail under 9.2 (#17942)
- Loading branch information
Showing
2 changed files
with
40 additions
and
0 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
37 changes: 37 additions & 0 deletions
37
tests/php/modules/calypsoify/test-class.jetpack-calypsoify.php
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 Calypsoify. | ||
* | ||
* @package Jetpack | ||
*/ | ||
|
||
require_jetpack_file( 'modules/calypsoify/class.jetpack-calypsoify.php' ); | ||
|
||
/** | ||
* Class WP_Test_Jetpack_Calypsoify | ||
*/ | ||
class WP_Test_Jetpack_Calypsoify extends WP_UnitTestCase { | ||
|
||
/** | ||
* Sets up each test. | ||
* | ||
* @inheritDoc | ||
*/ | ||
public function setUp() { | ||
parent::setUp(); | ||
$this->instance = Jetpack_Calypsoify::getInstance(); | ||
} | ||
|
||
/** | ||
* Sets up the Masterbar mock. | ||
* | ||
* For sites when Masterbar is not active, we mock it. This test confirms that functions. | ||
* | ||
* @covers Jetpack_Calypsoify::mock_masterbar_activation | ||
* @see https://github.com/Automattic/jetpack/pull/17939 | ||
*/ | ||
public function test_mock_masterbar_activation() { | ||
$this->instance->mock_masterbar_activation(); | ||
$this->assertTrue( class_exists( '\Automattic\Jetpack\Dashboard_Customizations\Masterbar' ) ); | ||
} | ||
} |