Part of meta issue #500866: [META] remove t() from assert message.

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 38 changes needed in 4 Test files. This issue includes conversion of all format_patch() occurances as well.

Files: 
CommentFileSizeAuthor
#7 statistics-1797520-7.patch13.54 KBdcam
PASSED: [[SimpleTest]]: [MySQL] 39,469 pass(es).
[ View ]
#4 1797520-4-t-statistics.patch13.26 KBLars Toomre
PASSED: [[SimpleTest]]: [MySQL] 41,896 pass(es).
[ View ]
#2 1797520-2-t-statistics.patch13.87 KBLars Toomre
FAILED: [[SimpleTest]]: [MySQL] Invalid PHP syntax in core/modules/statistics/lib/Drupal/statistics/Tests/StatisticsReportsTest.php.
[ View ]

Comments

Lars Toomre’s picture

Assigned:xjm» Lars Toomre

Patch forthcoming for this one!

Lars Toomre’s picture

Status:Active» Needs review
StatusFileSize
new13.87 KB
FAILED: [[SimpleTest]]: [MySQL] Invalid PHP syntax in core/modules/statistics/lib/Drupal/statistics/Tests/StatisticsReportsTest.php.
[ View ]

Here is an initial patch for this issue. It includes conversion(s) to format_string().

Status:Needs review» Needs work

The last submitted patch, 1797520-2-t-statistics.patch, failed testing.

Lars Toomre’s picture

Status:Needs work» Needs review
StatusFileSize
new13.26 KB
PASSED: [[SimpleTest]]: [MySQL] 41,896 pass(es).
[ View ]

Whoops... Deleted one too many ) there. This should fix that.

xjm’s picture

Assigned:Lars Toomre» jhodgdon
Status:Needs review» Reviewed & tested by the community

All correct.

jhodgdon’s picture

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

Thanks! Committed to 8.x.

dcam’s picture

Status:Patch (to be ported)» Needs review
StatusFileSize
new13.54 KB
PASSED: [[SimpleTest]]: [MySQL] 39,469 pass(es).
[ View ]

Backported #4 to D7.

Status:Needs review» Needs work
Issue tags:-needs backport to D7

The last submitted patch, statistics-1797520-7.patch, failed testing.

dcam’s picture

Status:Needs work» Needs review
Issue tags:+needs backport to D7

#7: statistics-1797520-7.patch queued for re-testing.

Lars Toomre’s picture

Status:Needs review» Reviewed & tested by the community

I have checked all of the changes proposed in #7 and they are all correct. I did not check whether this covers all of the changes in the Tests for the Statistics module because I did not apply the patch to D7 install. FRom my perspective, this is RTBC!

webchick’s picture

Assigned:Unassigned» jhodgdon

Tum te tum...

jhodgdon’s picture

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

Thanks! Committed to 7.x.

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

Anonymous’s picture

Issue summary:View changes

Added count details.