One of the ways the bug in #2979882: "The machine-readable name is already in use" error when adding multiple source keys can be reproduced, is in the following way:

  1. Add a target
  2. From the sources select list, select "New custom source.." and type in a source value.
  3. Configure target configuration.

So to write a test for the bug, it would be good to involve setting target configuration for it. There's however no test coverage for this action yet and it is stated as @todo in FeedsJavascriptTestBase::addMappings().

So let's add that. And while we are at it, break down FeedsJavascriptTestBase::addMappings() into multiple methods so the other issue could more easily do steps on the mapping form in a different order. Because the bug from the other issue is not exposed when setting target configuration first and set custom sources after.

Patch will follow.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

MegaChriz created an issue. See original summary.

MegaChriz’s picture

  • MegaChriz committed 5f3adf6 on 8.x-3.x
    Issue #3116977 by MegaChriz: Added js test coverage for setting target...
MegaChriz’s picture

Status: Needs review » Fixed

Committed #2.

Status: Fixed » Closed (fixed)

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