Problem/Motivation

Right now the web test tests one set of config. Now that #2676266: There is no option for no markup is upon us, it might be good to create a Kernel test to easily test a lot more variations of config and output quickly.

Proposed resolution

Write more tests!

Remaining tasks

Write more tests!

User interface changes

None.

API changes

None.

Data model changes

None.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Sam152 created an issue. See original summary.

Sam152’s picture

Status: Needs review » Needs work

The last submitted patch, 2: 2683305-config-variations-test-2.patch, failed testing.

The last submitted patch, 2: 2683305-config-variations-test-2.patch, failed testing.

The last submitted patch, 2: 2683305-config-variations-test-2.patch, failed testing.

The last submitted patch, 2: 2683305-config-variations-test-2.patch, failed testing.

The last submitted patch, 2: 2683305-config-variations-test-2.patch, failed testing.

The last submitted patch, 2: 2683305-config-variations-test-2.patch, failed testing.

The last submitted patch, 2: 2683305-config-variations-test-2.patch, failed testing.

benjy’s picture

Looks RTBC to me, just 2 things:

  1. +++ b/src/Tests/IntegrationTest.php
    @@ -0,0 +1,79 @@
    +//  protected $profile = 'standard';
    

    Commented out profile?

  2. +++ b/src/Tests/IntegrationTest.php
    @@ -0,0 +1,79 @@
    +    $this->assertTrue(strpos($this->stripWhitespace($page), $this->stripWhitespace($expected_field_markup)) !== FALSE, 'Found the correct field markup on the page.');
    

    phpunit has a assertContains?

Sam152’s picture

  • Sam152 committed 125e421 on 8.x-2.x
    Issue #2683305 by Sam152, benjy: Test more variations of configuration...
Sam152’s picture

Status: Needs review » Fixed
Sam152’s picture

Thanks for the review. Profile fixed. The whitespace is amongst the field output, not strictly at the start or end, so both need extraneous whitespace removed everywhere.

Status: Fixed » Closed (fixed)

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