This is a sub-task of #500866: [META] remove t() from assert message focused on the Tracker module.

In D8 per http://drupal.org/simpletest-tutorial-drupal7#t, best practice is to remove t() from assert messages in tests. When necessary, t() should be replaced with format_string().

There are approximately 21 changes needed in a single test file. This issue includes conversion of all format_patch() occurances as well.

Files: 
CommentFileSizeAuthor
#5 1798366-5-tracker.patch6.7 KBdcam
PASSED: [[SimpleTest]]: [MySQL] 40,098 pass(es). View
#1 1798366-1-tracker.patch7.24 KBLars Toomre
PASSED: [[SimpleTest]]: [MySQL] 41,897 pass(es). View

Comments

Lars Toomre’s picture

Title: Remove t() from test asserts from Tracker mdoule » Remove t() from test asserts in Tracker mdoule
Status: Active » Needs work
FileSize
7.24 KB
PASSED: [[SimpleTest]]: [MySQL] 41,897 pass(es). View

Here is an initial untested patch for this issue. This patch includes format_string() conversions as well.

Lars Toomre’s picture

Status: Needs work » Needs review

Helps to set right status.

dcam’s picture

Status: Needs review » Reviewed & tested by the community

Easy review. #1 looks good. I didn't find any additional t()'s around assert messages in the tracker module.

jhodgdon’s picture

Version: 8.x-dev » 7.x-dev
Status: Reviewed & tested by the community » Patch (to be ported)

Thanks! Committed to 8.x, ready for backport.

dcam’s picture

Status: Patch (to be ported) » Needs review
FileSize
6.7 KB
PASSED: [[SimpleTest]]: [MySQL] 40,098 pass(es). View

Backported #1 to D7.

dcam’s picture

#5: 1798366-5-tracker.patch queued for re-testing.

dcam’s picture

Issue tags: +Novice

Tagging as Novice.

cilefen’s picture

Status: Needs review » Reviewed & tested by the community

#5 for D7 looks good to me. All t()'s are removed around assert messages.

jhodgdon’s picture

Assigned: Unassigned » jhodgdon

Thanks! I'll give this a final review and commit shortly.

jhodgdon’s picture

Assigned: jhodgdon » Unassigned
Status: Reviewed & tested by the community » Fixed

Thanks again! This is committed to 7.x.

There are only a few more of these issues left!!!

Automatically closed -- issue fixed for 2 weeks with no activity.

Anonymous’s picture

Issue summary: View changes

Added count details.