Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Albert Volkman’s picture

Status: Active » Needs review
FileSize
76.09 KB

Status: Needs review » Needs work

The last submitted patch, convert_menu_test_to_psr0-1598590-1.patch, failed testing.

aspilicious’s picture

You need to remove the old test file ;)

+++ b/core/modules/system/lib/Drupal/system/Tests/Menu/MenuLinksUnitTest.phpundefined
@@ -0,0 +1,226 @@
+ * Definition of Drupal\system\Tests\Menu\MenuLinksUnitTest.

Remove the "Unit" part

+++ b/core/modules/system/lib/Drupal/system/Tests/Menu/MenuLinksUnitTest.phpundefined
@@ -0,0 +1,226 @@
+class MenuLinksUnitTest extends WebTestBase {

Same

+++ b/core/modules/system/lib/Drupal/system/Tests/Menu/MenuRouterTest.phpundefined
@@ -0,0 +1,552 @@
+ * Definition of Drupal\system\Tests\Menu\MenuLinksRouterTest.

Must be MenuRouterTest

+++ b/core/modules/system/lib/Drupal/system/Tests/Menu/MenuTreeDataTest.phpundefined
@@ -0,0 +1,65 @@
+ * Definition of Drupal\system\Tests\Menu\MenuTreeDataTest.

Here I would add "Unit" before Test like we did with other unit tests

+++ b/core/modules/system/lib/Drupal/system/Tests/Menu/MenuTreeDataTest.phpundefined
@@ -0,0 +1,65 @@
+class MenuTreeDataTest extends UnitTestBase {

Same, add Unit (and don't forget to rename the file)

22 days to next Drupal core point release.

Albert Volkman’s picture

Status: Needs work » Needs review
FileSize
98.14 KB

Thanks for the review!

Status: Needs review » Needs work

The last submitted patch, convert_menu_test_to_psr0-1598590-4.patch, failed testing.

Albert Volkman’s picture

Didn't load MenuWebTest.

Albert Volkman’s picture

Status: Needs work » Needs review

Status: Needs review » Needs work

The last submitted patch, convert_menu_test_to_psr0-1598590-6.patch, failed testing.

aspilicious’s picture

Srry one more thing.

+++ b/core/modules/system/lib/Drupal/system/Tests/Menu/MenuWebTest.phpundefined
@@ -0,0 +1,127 @@
+ * Definition of Drupal\system\Tests\Menu\MenuWebTest.

Can we make this MenuTest?

+++ b/core/modules/system/lib/Drupal/system/Tests/Menu/MenuWebTest.phpundefined
@@ -0,0 +1,127 @@
+class MenuWebTest extends WebTestBase {

Same

AND
class MenuBreadcrumbTest extends MenuWebTestCase
class MenuTrailTest extends MenuWebTestCase {

should extend MenuWebTestBase

You can fix all of this by applying this patch and just fix the few small problems that are left

22 days to next Drupal core point release.

Albert Volkman’s picture

Since the class MenuWebTestCase is now MenuTest, shouldn't they be extending MenuTest instead of MenuWebTestBase?

aspilicious’s picture

Base classes should end in Base so you should rename MenuTest to MenuTestBase

Albert Volkman’s picture

Status: Needs work » Needs review
FileSize
98.14 KB

Status: Needs review » Needs work

The last submitted patch, convert_menu_test_to_psr0-1598590-12.patch, failed testing.

Albert Volkman’s picture

Status: Needs work » Needs review
FileSize
148.4 KB

Re-roll.

Albert Volkman’s picture

Renamed functions removing preceding Menu.

aspilicious’s picture

Status: Needs review » Needs work
+++ b/core/modules/system/lib/Drupal/system/Tests/Menu/BreadcrumbTest.phpundefined
@@ -0,0 +1,503 @@
+use Drupal\system\Tests\Menu\TestBase;

TestBase is located in the same namespace so you can remove this line

+++ b/core/modules/system/lib/Drupal/system/Tests/Menu/TrailTest.phpundefined
@@ -0,0 +1,211 @@
+use Drupal\system\Tests\Menu\TestBase;

Same

21 days to next Drupal core point release.

Albert Volkman’s picture

Status: Needs work » Needs review
FileSize
148.18 KB

Patchin' away.

Status: Needs review » Needs work

The last submitted patch, convert_menu_test_to_psr0-1598590-17.patch, failed testing.

Niklas Fiekas’s picture

Thanks @Albert Volkman!

+++ b/core/modules/system/lib/Drupal/system/Tests/Menu/TrailTest.phpundefined
@@ -0,0 +1,209 @@
+class TrailTest extends MenuWebTest {

That one should probably extend MenuTestBase, no?

Albert Volkman’s picture

Nah, that'd make too much sense. ;-)

Albert Volkman’s picture

Status: Needs work » Needs review

Status: Needs review » Needs work

The last submitted patch, convert_menu_test_to_psr0-1598590-20.patch, failed testing.

aspilicious’s picture

RouterTest.php needs a "use PDO;" on top of the file

Albert Volkman’s picture

Good times.

Albert Volkman’s picture

Status: Needs work » Needs review
RobLoach’s picture

FileSize
97.51 KB

Same patch with the rename detection, and without the system.info hunk.

aspilicious’s picture

Status: Needs review » Reviewed & tested by the community

Good to go!

RobLoach’s picture

#26: 1598590.patch queued for re-testing.

webchick’s picture

Status: Reviewed & tested by the community » Fixed

Committed and pushed to 8.x. Thanks!

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