Files: 
CommentFileSizeAuthor
#9 8.x-rename-views-method-2002900-9.patch5.22 KBdiarmy
PASSED: [[SimpleTest]]: [MySQL] 56,007 pass(es). View
#7 8.x-rename-views-method-2002900-7.patch5.24 KBdiarmy
PASSED: [[SimpleTest]]: [MySQL] 55,720 pass(es). View
#7 interdiff.txt683 bytesdiarmy
#3 8.x-rename-views-method-2002900-3.patch5.23 KBdiarmy
PASSED: [[SimpleTest]]: [MySQL] 55,686 pass(es). View
#3 interdiff.txt1014 bytesdiarmy
#2 8.x-rename-views-method-2002900-2.patch4.41 KBdiarmy
FAILED: [[SimpleTest]]: [MySQL] Repository checkout: failed to checkout from [git://git.drupal.org/project/drupal.git]. View
#2 argument_default_test_result.png99.33 KBdiarmy

Comments

diarmy’s picture

Assigned: Unassigned » diarmy

Working on it!

diarmy’s picture

Status: Active » Needs review
FileSize
99.33 KB
4.41 KB
FAILED: [[SimpleTest]]: [MySQL] Repository checkout: failed to checkout from [git://git.drupal.org/project/drupal.git]. View
  • Replaced all instances of get_default_argument() with getDefaultArgument() in views, including the tests.
  • Ran simpletest with all tests passing (see attached screenshot)
diarmy’s picture

FileSize
1014 bytes
5.23 KB
PASSED: [[SimpleTest]]: [MySQL] 55,686 pass(es). View

The patch in #2 did not take into account instances of get_default_argument() used outside of the views module. After grepping the whole site, another example was located in core/modules/user/lib/Drupal/user/Tests/Views/ArgumentDefaultTest.php. This updated patch includes the conversion to getDefaultArgument for this too.

Status: Needs review » Needs work
Issue tags: -Novice, -VDC

The last submitted patch, 8.x-rename-views-method-2002900-3.patch, failed testing.

diarmy’s picture

Status: Needs work » Needs review
Issue tags: +Novice, +VDC
diarmy’s picture

Just realised that I need to add the public modifier before function getDefaultArgument() to adhere to OOP standards, so I'll get cracking with that.

diarmy’s picture

FileSize
683 bytes
5.24 KB
PASSED: [[SimpleTest]]: [MySQL] 55,720 pass(es). View

This version includes the public modifier before function getDefaultArgument() in core/modules/views/lib/Drupal/views/Plugin/views/argument/ArgumentPluginBase.php.

oenie’s picture

Status: Needs review » Needs work
+++ b/core/modules/views/lib/Drupal/views/Plugin/views/argument/Date.phpundefined
@@ -57,7 +57,7 @@ function default_argument_form(&$form, &$form_state) {
+  function getDefaultArgument($raw = FALSE) {

Add public access modifier in front of the function to adhere to the new OOP standards.

diarmy’s picture

FileSize
5.22 KB
PASSED: [[SimpleTest]]: [MySQL] 56,007 pass(es). View

I started over again, this time remembering to add the public access modifier in front of the function.

diarmy’s picture

Status: Needs work » Needs review

Updating status to needs review

dawehner’s picture

Status: Needs review » Reviewed & tested by the community

Cool.

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

Committed 0449064 and pushed to 8.x. Thanks!

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