Problem/Motivation
While debugging #2226533: Changes to the Language class due to the LanguageInterface (followup) I looked at the a failing test with the text Found English variant of tip 1. and I was
for a moment confused about exactly what was broken because of the assertion text was duplicated and I had to figure out
which test was broken and which test was not.
$this->assertEqual(count($elements), 1,<strong> 'Found English variant of tip 1.'</strong>);
// Navigate to tour-test-3 and verify the tour_test_1 tip is not found with
// appropriate classes.
$this->drupalGet('tour-test-3/bar');
$elements = $this->xpath('//li[@data-id=:data_id and @class=:classes and ./h2[contains(., :text)]]', array(
':classes' => 'tip-module-tour-test tip-type-text tip-tour-test-1',
':data_id' => 'tour-test-1',
':text' => 'The first tip',
));
$this->assertEqual(count($elements), 0, <strong>'Found English variant of tip 1.'</strong>);
clearly the second assertEquals shown above if mislabeled because it is looking for a count of 0
and should read something like 'Did not find English variant of tip 1'
Remaining tasks
none
User interface changes
none
API changes
none
Comments
Comment #1
martin107 commentedComment #2
larowlanThanks
Comment #3
dries commentedCommitted to 8.x. Thanks.