Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Dave Reid created an issue. See original summary.

Dave Reid’s picture

Status: Active » Needs review
Issue tags: +Needs tests
FileSize
547 bytes

Appears we had duplicate lines in the default config. And now we'll need tests to ensure this works out of the box.

Dave Reid’s picture

Title: Strings to remove does set properly » Strings to remove default setting is incorrect
Issue tags: +Needs update path
Dave Reid’s picture

With update hook, still needs tests.

Berdir’s picture

Status: Needs review » Needs work

Needs a reroll as we have new update functions.

gaurav.goyal’s picture

Patch Rerolled. Updating status to needs review so that bots can review the patch.

gaurav.goyal’s picture

Status: Needs work » Needs review
gaurav.goyal’s picture

One of the test for pathauto_cleanstring() function still uses old configuration as default value. I think we missed to update this.

Pathauto Test Code

Attached patch contains the update.

Berdir’s picture

What about using installConfig('pathauto') to install the default config and check with those settings? then we have that covered.

dermario’s picture

I attached the the changes to the settings form webtest, to ensure the changes introduced by patch in #8 will not break the tests introduced by https://www.drupal.org/node/2674494

This test will also check if the default values in the form are set correctly.

What about using installConfig('pathauto') to install the default config and check with those settings?

Do you mean we should use $this->installConfig(array('pathauto')) in PathautoUnitTest::testCleanString() instead of using $config->set() ?

Berdir’s picture

Yes, that's exactly what I meant. Assuming the default configuration actually matches what we save there, if not, then comment so and we'll ignore that, at least for this issue.

Berdir’s picture

Status: Needs review » Needs work
dermario’s picture

Assigned: Unassigned » dermario
dermario’s picture

I gave it a try to refactor the test to use installConfig() and completely rely on settings in pathauto.settings.yml

Berdir’s picture

Status: Needs review » Reviewed & tested by the community
Issue tags: -Needs tests

Nice, I like that.

Berdir’s picture

Status: Reviewed & tested by the community » Fixed

Thanks, committed.

  • Berdir committed e015503 on 8.x-1.x authored by dermario
    Issue #2656958 by Dave Reid, dermario, gaurav.goyal: Strings to remove...

Status: Fixed » Closed (fixed)

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