wordpress-develop/tests/phpunit/tests/date
SergeyBiryukov 54e1b4b959 Coding Standards: Use pre-increment/decrement for stand-alone statements.
Note: This is enforced by WPCS 3.0.0:

1. There should be no space between an increment/decrement operator and the variable it applies to.
2. Pre-increment/decrement should be favoured over post-increment/decrement for stand-alone statements. “Pre” will in/decrement and then return, “post” will return and then in/decrement. Using the “pre” version is slightly more performant and can prevent future bugs when code gets moved around.

References:
* [https://developer.wordpress.org/coding-standards/wordpress-coding-standards/php/#increment-decrement-operators WordPress PHP Coding Standards: Increment/decrement operators]
* [https://github.com/WordPress/WordPress-Coding-Standards/pull/2130 WPCS: PR #2130 Core: add sniffs to check formatting of increment/decrement operators]

Props jrf.
See #59161, #58831.

git-svn-id: https://develop.svn.wordpress.org/trunk@56549 602fd350-edb4-49c9-b593-d223f7449a82
2023-09-09 09:26:01 +00:00
..
currentDatetime.php Date/Time: Add a unit test for the return type of current_datetime(). 2022-01-21 05:58:13 +00:00
currentTime.php Tests: Add tests with deprecated timezone strings. 2022-09-19 23:51:20 +00:00
dateI18n.php General: Increase the minimum supported version of PHP to 7.0.0. 2023-07-05 17:39:55 +00:00
getCommentDate.php Tests: Rename some classes in phpunit/tests/date/ per the naming conventions. 2021-02-11 21:20:41 +00:00
getFeedBuildDate.php Tests: Replace the timezone used in date/time tests. 2022-09-19 21:18:59 +00:00
getPermalink.php Tests: Reset timezone-related options if the tests change them. 2022-09-19 17:43:55 +00:00
getPostTime.php Tests: Replace the timezone used in date/time tests. 2022-09-19 21:18:59 +00:00
getTheDate.php Tests: Rename some classes in phpunit/tests/date/ per the naming conventions. 2021-02-11 21:20:41 +00:00
getTheModifiedDate.php Tests: Use the factory method instead of the property. 2022-09-06 22:09:49 +00:00
maybeDeclineDate.php Build/Test Tools: Implement use of the void solution. 2021-08-07 10:29:41 +00:00
mysql2date.php Tests: Add tests with deprecated timezone strings. 2022-09-19 23:51:20 +00:00
query.php Coding Standards: Remove superfluous blank lines at the end of various functions. 2023-09-08 10:01:14 +00:00
theDate.php Coding Standards: Use pre-increment/decrement for stand-alone statements. 2023-09-09 09:26:01 +00:00
wpDate.php Date/Time: Increase test coverage of wp_date(). 2022-08-01 22:48:42 +00:00
wpTimezone.php Tests: Use the data_ prefix for various data provider methods. 2023-03-19 12:03:30 +00:00
xmlrpc.php Code Modernization: Fix null to non-nullable deprecations in wp_xmlrpc_server::_insert_post(). 2022-09-27 02:16:28 +00:00