Skip to content

Tests/admin/includes/image: Rename wp_exif_date2ts test class - #16387

Closed
shail-mehta wants to merge 1 commit into
WordPress:trunkfrom
shail-mehta:tests/65208-admin-includes-image-wp-exif-date2ts
Closed

shail-mehta wants to merge 1 commit into
WordPress:trunkfrom
shail-mehta:tests/65208-admin-includes-image-wp-exif-date2ts

Conversation

@shail-mehta

Copy link
Copy Markdown
Member

What

Trac Ticket: #65208

Renames tests/phpunit/tests/admin/includes/image/wpExifDate2ts.php to Admin_Includes_Image_WpExifDate2ts_Test.php and updates the class from Tests_Admin_Includes_Image_WpExifDate2ts to Admin_Includes_Image_WpExifDate2ts_Test.

Why

filename and class name align with the method under test and end with _Test, consistent with recently landed admin renames. No test behavior changes.

How

  • Used git mv to preserve history
  • Renamed only the file and class
  • Left @covers ::wp_exif_date2ts, groups, fixtures, and the data provider unchanged

Testing instructions

  1. Run:
npm run test:php -- --test-suffix .php --filter Admin_Includes_Image_WpExifDate2ts_Test
  1. Optionally run the admin image folder:
npm run test:php -- --test-suffix .php tests/phpunit/tests/admin/includes/image
  1. Confirm PHPUnit still discovers and runs the same cases (2 data-provider rows for test_converts_exif_datetime_to_timestamp)

Use of AI tools

  • Assisted by Cursor

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

No active review issues are recorded for the test filename and class naming alignment.

No open issues 🎉

What changed in this PR

Aligns the wp_exif_date2ts test filename and class with the admin test naming convention.

Changes:

  • Renames the file and class to Admin_Includes_Image_WpExifDate2ts_Test.
  • Leaves test behavior, coverage annotations, fixtures, and the data provider unchanged.
File Description
tests/​phpunit/​tests/​admin/​includes/​image/​Admin_Includes_Image_WpExifDate2ts_Test.php Aligns the test filename and class with the _Test naming convention.

Review effort: Balanced

@shail-mehta
shail-mehta marked this pull request as ready for review December 2, 2026 17:54
@github-actions

github-actions Bot commented Dec 2, 2026

Copy link
Copy Markdown

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs.

Core Committers: Use this line as a base for the props when committing in SVN:

Props shailu25.

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.


Props Bot commands

You can trigger Props Bot actions by commenting on this PR:

  • @propsbot add <username> to give props to a GitHub or WordPress.org user. Requires write access.
  • @propsbot remove <username> to leave a user out of the props. Requires write access.
  • @propsbot refresh to refresh this list. Adding the props-bot label works too.

@lancewillett lancewillett left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verified all 2 single-site cases (2 assertions) and 2 multisite cases (2 assertions) before and after the rename. PHPUnit discovered the same cases with the same assertion counts in randomized order. The coverage annotations and fixtures are preserved.

AI review · gpt-6.2-astra

wporg-sync pushed a commit that referenced this pull request Dec 2, 2026
…n test classes and files.

Developed in: #16387, #16391, #16394

Props shailu25, jrf, desrosj.
See #65208.


git-svn-id: https://develop.svn.wordpress.org/trunk@65868 602fd350-edb4-49c9-b593-d223f7449a82
wporg-sync pushed a commit to WordPress/WordPress that referenced this pull request Dec 2, 2026
@lancewillett

Copy link
Copy Markdown
Member

@lancewillett lancewillett moved this from In review to Done in WordPress Project Build Tooling Dec 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

3 participants