mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-07-28 13:00:19 +00:00
Tests: Use more appropriate assertions in various tests.
This replaces instances of `assertTrue( in_array( ... ) )` with `assertContains()` to use native PHPUnit functionality. Follow-up to [51335], [51337], [51367], [51397], [51403]. Props hellofromTonya, jrf, SergeyBiryukov. Fixes #53123. See #53363. git-svn-id: https://develop.svn.wordpress.org/trunk@51404 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -208,7 +208,7 @@ class Tests_Theme_ThemeDir extends WP_UnitTestCase {
|
||||
$this->assertNotEmpty( $theme );
|
||||
|
||||
$templates = $theme['Template Files'];
|
||||
$this->assertTrue( in_array( $this->theme_root . '/page-templates/template-top-level.php', $templates, true ) );
|
||||
$this->assertContains( $this->theme_root . '/page-templates/template-top-level.php', $templates );
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user