NoHelpTest is designed to look at admin/help and verify that there is NO help link for a module that doesn't implement hook_help().
But NoHelpTest uses the 'testing' profile, and in the testing profile the help module is not enabled! Thus admin/help never shows anything - indeed if you run the test interactively you'll see that visiting admin/help produces a 404 Page not found. There will NEVER be any help links on admin/help in the testing profile without the help module enabled, and this test will always run green even if the help module is broken.
To fix this, we need to enable the help module in the test.
To make sure this doesn't break again, we also have to check for a 200 response when requesting admin/help and check that we are really seeing the correct page by verifying the presence of some known text on that page.
Patch attached.
Comment | File | Size | Author |
---|---|---|---|
help.patch | 1.02 KB | TR | |
Comments
Comment #1
BerdirMakes sense, can you upload a test-only patch that only contains the failures and proves that this fixes it?
Comment #2
jhodgdonRather than asking for a different patch, I ran the "no help" test manually without and then with the patch, with debugging output turned on.
I have confirmed that without the patch, the line
$this->drupalGet('admin/help');
goes to a 404, as noted in the issue here, and the test "passes" because there is no help text on that page at all.
I have also confirmed that with the patch, the drupalGet goes to the actual help page, and so the test is now valid.
So, having manually tested the patch, I think it is ready to go in.
Comment #3
webchickSo would you say then that NoHelpTest is.... no help? ;)
Committed and pushed to 8.x. Thanks!