Problem/Motivation

In order to make changes to the module, as a developer, I want automated regression tests, so that I can be confident that my changes have not broken the module.

Proposed resolution

Add tests.

Remaining tasks

  1. Write patch
  2. Review and feedback
  3. RTBC and feedback
  4. Merge
  5. Enable automated testing in project settings

User interface changes

None.

API changes

None.

Data model changes

None.

Release notes snippet

To be determined.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mparker17 created an issue. See original summary.

mparker17’s picture

FileSize
11.58 KB

Here's a preliminary patch to add tests.

I have an issue with my local setup, and I'd like to rebuild my local environment to fix it, but I'm uploading this patch to take a snapshot of my work thus far. It is entirely possible this patch will fail spectacularly.

Essentially, I'm following the direction that Views' own \Drupal\Tests\views\Functional\Plugin\StyleTableTest and \Drupal\Tests\views\Functional\Plugin\StyleOpmlTest tests take for testing built-in Views Style plugins, which is to define a custom view in a hidden testing module, and run Functional tests on that view.

mparker17’s picture

Status: Active » Needs review
FileSize
11.9 KB
2.65 KB

Okay, this should work now!

mparker17’s picture

Issue summary: View changes
FileSize
12.29 KB
1.14 KB

Fixed a poorly-worded comment and added a test to make sure the JavaScript library is correctly output on pages where the jump menu is used.

jcnventura’s picture

Status: Needs review » Reviewed & tested by the community
FileSize
1.16 KB
11.61 KB

Testing modules do not need the core_version_requirement line. And the new test module should be in the tests directory.

  • mparker17 authored da5578d on 8.x-1.x
    Issue #3161264 by mparker17, jcnventura: Add automated tests
    
jcnventura’s picture

Status: Reviewed & tested by the community » Fixed

Now to enable these tests.

mparker17’s picture

Issue summary: View changes

Awesome, thanks!

Status: Fixed » Closed (fixed)

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