Problem/Motivation

#2226533: Changes to the Language class due to the LanguageInterface (followup) was
diff --git a/core/modules/language/src/Tests/LanguageUrlRewritingTest.php b/core/modules/language/src/Tests/LanguageUrlRewritingTest.php
index 3701fb9..94dcd2f 100644
--- a/core/modules/language/src/Tests/LanguageUrlRewritingTest.php
+++ b/core/modules/language/src/Tests/LanguageUrlRewritingTest.php
@@ -52,7 +53,7 @@ protected function setUp() {
function testUrlRewritingEdgeCases() {
// Check URL rewriting with a non-installed language.
$non_existing = \Drupal::languageManager()->getDefaultLanguage();
- $non_existing->id = $this->randomMachineName();
+ $non_existing->setId($this->randomMachineName());
$this->checkUrl($non_existing, 'Path language is ignored if language is not installed.', 'URL language negotiation does not work with non-installed languages');

// Check that URL rewriting is not applied to subrequests.

but there is no setId()

Proposed resolution

handle this better, maybe in the create/new passing to the constructor.

Remaining tasks

User interface changes

No.

API changes

No.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

YesCT’s picture

Issue summary: View changes
martin107’s picture

I am looking at this now..

but first I have a nit-pick to be removed as a separate issue. :)

martin107’s picture

Assigned: martin107 » Unassigned
Status: Active » Needs review
FileSize
1.13 KB

Adopting the much cleaner way of overriding the defaults when constructing a new language.

LanguageUrlRewritingTest.php passes locally for me.

martin107’s picture

and after a little nudging, by the eagle eyed YesCT... I eventually do the right thing :)

YesCT’s picture

Status: Needs review » Reviewed & tested by the community

super.

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

Committed f6d2f23 and pushed to 8.0.x. Thanks!

  • alexpott committed f6d2f23 on 8.0.x
    Issue #2337859 by martin107 | YesCT: LanguageUrlRewritingTest should not...

Status: Fixed » Needs work

The last submitted patch, 4: languageUrl-2337859-4.patch, failed testing.

YesCT’s picture

Status: Needs work » Fixed

I *think* the testbot tried to retest this since it was rtbc, but .. alexpott had just committed it, so it did not apply? It was green...

Status: Fixed » Closed (fixed)

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