Since the menu unit tests weren't really working, we just removed them for now from the module in #2482655: Drupal.org test bot doesn't run our PHPUnit tests to get the tests passing again.
Of course, removing failing tests isn't really a viable plan in the long run, so we should re-add them.

Estimated Value and Story Points

This issue was identified as a Beta Blocker for Drupal 8. We sat down and figured out the value proposition and amount of work (story points) for this issue.

Value and Story points are in the scale of fibonacci. Our minimum is 1, our maximum is 21. The higher, the more value or work a certain issue has.

Value : 1
Story Points: 5

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

drunken monkey’s picture

Status: Active » Needs review
FileSize
3.09 KB

Here is the patch that would just re-add the old tests, in the propre location.
But it's of course expected to fail.

Status: Needs review » Needs work

The last submitted patch, 1: 2493863-1--readd_menu_unit_tests.patch, failed testing.

Nick_vh’s picture

Issue summary: View changes
Issue tags: +beta blocker
borisson_’s picture

Status: Needs work » Needs review
FileSize
1.81 KB
2.45 KB

I deleted the LocalActionsTest as that one was empty anyway and made sure the LocalTasksTest works.

This is probably not going to work on every machine because in the ::setUp method we refer to the 'modules/search_api' module. I'll see if I can figure that out.

borisson_’s picture

The code fix my comment in #4 was actually really simple. See attached patch.

drunken monkey’s picture

+++ b/tests/src/Unit/Menu/LocalTasksTest.php
@@ -0,0 +1,100 @@
+    return array(
+      array('entity.search_api_index.canonical'),
+      array('entity.search_api_index.edit_form'),
+      array('entity.search_api_index.processors'),
+    );

Any reason why that doesn't contain the "Fields" tab? (Worked fine for me with it, too, so adding that.)

Otherwise, looks pretty good, thanks for making it work!

borisson_’s picture

No specific reason, no. I just forgot :(

Nick_vh’s picture

No need to be sad! This patch is looking great. Good candidate for RTBC. If someone can verify this works locally we can set that to RTBC even

drunken monkey’s picture

No need to be sad! This patch is looking great. Good candidate for RTBC. If someone can verify this works locally we can set that to RTBC even

I tested it locally, as hinted, so it should be OK.
Also, I think we can trust the test bot again, both issues were fixed.

borisson_’s picture

Status: Needs review » Reviewed & tested by the community

Since all 3 of us think it's RTBC, I'll bite the bullet and actually change the issue status.

drunken monkey’s picture

Status: Reviewed & tested by the community » Fixed

Very courageous of you, I applaud your audacity!
Committed.
Thanks again!

Status: Fixed » Closed (fixed)

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