forked from php-stubs/wordpress-stubs
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/master'
- Loading branch information
Showing
14 changed files
with
3,164 additions
and
697 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,6 +20,9 @@ jobs: | |
php-version: | ||
- "7.4" | ||
- "8.0" | ||
- "8.1" | ||
- "8.2" | ||
- "8.3" | ||
|
||
steps: | ||
- name: "Checkout repository" | ||
|
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
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
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 |
---|---|---|
@@ -1,17 +1,17 @@ | ||
<?php | ||
|
||
declare( strict_types=1 ); | ||
declare(strict_types=1); | ||
|
||
namespace PhpStubs\WordPress\Core\Tests; | ||
|
||
use function get_term; | ||
use function PHPStan\Testing\assertType; | ||
|
||
assertType( 'WP_Error|WP_Term|null', get_term( 2, '', OBJECT ) ); | ||
assertType( 'WP_Error|WP_Term|null', get_term( 2, 'category', OBJECT ) ); | ||
assertType( 'WP_Error|WP_Term|null', get_term( 2 ) ); | ||
assertType('WP_Error|WP_Term|null', get_term(2, '', OBJECT)); | ||
assertType('WP_Error|WP_Term|null', get_term(2, 'category', OBJECT)); | ||
assertType('WP_Error|WP_Term|null', get_term(2)); | ||
|
||
assertType( 'array<string, int|string>|WP_Error|null', get_term( 2, '', ARRAY_A ) ); | ||
assertType( 'array<string, int|string>|WP_Error|null', get_term( 2, 'category', ARRAY_A ) ); | ||
assertType( 'list<int|string>|WP_Error|null', get_term( 2, '', ARRAY_N ) ); | ||
assertType( 'list<int|string>|WP_Error|null', get_term( 2, 'category', ARRAY_N ) ); | ||
assertType('array<string, int|string>|WP_Error|null', get_term(2, '', ARRAY_A)); | ||
assertType('array<string, int|string>|WP_Error|null', get_term(2, 'category', ARRAY_A)); | ||
assertType('list<int|string>|WP_Error|null', get_term(2, '', ARRAY_N)); | ||
assertType('list<int|string>|WP_Error|null', get_term(2, 'category', ARRAY_N)); |
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 |
---|---|---|
@@ -1,13 +1,13 @@ | ||
<?php | ||
|
||
declare( strict_types=1 ); | ||
declare(strict_types=1); | ||
|
||
namespace PhpStubs\WordPress\Core\Tests; | ||
|
||
use function get_term_by; | ||
use function PHPStan\Testing\assertType; | ||
|
||
assertType( 'WP_Error|WP_Term|false', get_term_by( 'term_id', 2, '', OBJECT ) ); | ||
assertType( 'WP_Error|WP_Term|false', get_term_by( 'slug', 'test' ) ); | ||
assertType( 'array<string, int|string>|WP_Error|false', get_term_by( 'term_id', 2, '', ARRAY_A ) ); | ||
assertType( 'list<int|string>|WP_Error|false', get_term_by( 'term_id', 2, '', ARRAY_N ) ); | ||
assertType('WP_Error|WP_Term|false', get_term_by('term_id', 2, '', OBJECT)); | ||
assertType('WP_Error|WP_Term|false', get_term_by('slug', 'test')); | ||
assertType('array<string, int|string>|WP_Error|false', get_term_by('term_id', 2, '', ARRAY_A)); | ||
assertType('list<int|string>|WP_Error|false', get_term_by('term_id', 2, '', ARRAY_N)); |
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
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.