From 626f78750bb39fa3b11779b8348045e71d106b0a Mon Sep 17 00:00:00 2001 From: Drew Jaynes Date: Fri, 30 Jun 2017 04:35:39 +0000 Subject: [PATCH] Tests: Add `@method` notations to factor class DocBlocks as a way to indicate expected return types from factory methods for the benefit of IDEs. Props jdgrimes. Fixes #37867. git-svn-id: https://develop.svn.wordpress.org/trunk@40968 602fd350-edb4-49c9-b593-d223f7449a82 --- .../factory/class-wp-unittest-factory-for-blog.php | 10 ++++++++++ .../class-wp-unittest-factory-for-bookmark.php | 7 +++++++ .../class-wp-unittest-factory-for-comment.php | 10 ++++++++++ .../class-wp-unittest-factory-for-network.php | 10 ++++++++++ .../factory/class-wp-unittest-factory-for-post.php | 10 ++++++++++ .../factory/class-wp-unittest-factory-for-term.php | 12 ++++++++++++ .../factory/class-wp-unittest-factory-for-user.php | 10 ++++++++++ 7 files changed, 69 insertions(+) diff --git a/tests/phpunit/includes/factory/class-wp-unittest-factory-for-blog.php b/tests/phpunit/includes/factory/class-wp-unittest-factory-for-blog.php index 795f09f8b7..a62bbdd828 100644 --- a/tests/phpunit/includes/factory/class-wp-unittest-factory-for-blog.php +++ b/tests/phpunit/includes/factory/class-wp-unittest-factory-for-blog.php @@ -1,5 +1,15 @@ create( $args, $generation_definitions ); $taxonomy = isset( $args['taxonomy'] ) ? $args['taxonomy'] : $this->taxonomy; diff --git a/tests/phpunit/includes/factory/class-wp-unittest-factory-for-user.php b/tests/phpunit/includes/factory/class-wp-unittest-factory-for-user.php index 4c1151a8a5..1140e26153 100644 --- a/tests/phpunit/includes/factory/class-wp-unittest-factory-for-user.php +++ b/tests/phpunit/includes/factory/class-wp-unittest-factory-for-user.php @@ -1,5 +1,15 @@