Problem/Motivation

With the refactoring in 2.x we need a whole bunch of new tests. Maybe it's a good moment to re-think our testing approach to make all of them easier to maintain and cover the most use cases possible.

Proposed resolution

✔️ 1) Kernel: 
✔️  - All API methods
✔️ 2) Configuration form:
✔️  - Ensure UI elements are the ones we expect
✔️  - Ensure they do what is expected from them
✔️    -> The functionality itself can be tested programmatically, not through UI
✔️ 3) Integration test (implicitly tests entity_reference and link plugins)
✔️  - Basic CRUD in referenced nodes: 
✔️    * add target in field
✔️    * have 2 different targets in same field
✔️    * have duplicated targets in same field
✔️    * remove from field
✔️    * delete target
✔️    * delete host
✔️  - Deleting field storage should clean all usage tracked on this field
✔️ 4) Embedded content test:
✔️  - Should test logic specific to plugins:
✔️    * Entity Embed
✔️        - Single and multiple-entity tracking on the same field
✔️    * LinkIt
✔️        - Single and multiple-entity tracking on the same field
✔️        - References to non-existing entities don't register usage
✔️    * HtmlLink
✔️        - Single and multiple-entity tracking on the same field
✔️        - References to non-existing entities don't register usage
✔️        - Absolute and relative URLs
✔️        - Aliased URLs
✔️  - Test a plugin that tracks 2 field types (2952174)
✔️ 5) Config entities test:
✔️  - Should test logic specific to plugins:
✔️    * Entity Reference (when pointing to webforms)
✔️    * Block Field
✔️ 6) List controller test:
✔️  - All elements on the page are the ones we expect
✔️  - Correctly filter out garbage from `entity_usage`
✔️ 7) RevisionsTranslations test:
✔️  - Revisions are tracked correctly
✔️  - Translations are tracked correctly
✔️  - They work as expected in combination :) (2954638)
✔️  - Deleting node with hundreds of revisions correctly release all usage records
✔️  - We don't show duplicate usage on usage page (if translation not affected)
✔️ 8) Views test
✔️  - Test view integration with content entities with numeric IDs
✔️ 9) Paragraphs test
✔️  - Basic usage tracking of media entity inside paragraph on a node (2952448)
✔️  - Usage page shows parent's label
✔️  - Usage page skips orphan paragraph
✔️  - Nested paragraphs correctly store usage, and usage page shows the first non-paragraph parents label
✔️ 10) Batch update test
✔️  - Batch update page has specific permission
✔️  - Batch operation works
✔️  - Batch operation respects settings from config form

Remaining tasks

User interface changes

API changes

Data model changes

Comments

marcoscano created an issue. See original summary.

seanb’s picture

Issue summary: View changes

Added more issues missing tests.

marcoscano’s picture

Version: 8.x-1.x-dev » 8.x-2.x-dev
marcoscano’s picture

Issue summary: View changes

Added another missing test scenario we need to cover.

marcoscano’s picture

Issue summary: View changes

  • marcoscano committed 148b5ac on 8.x-2.x
    Issue #2952008 by marcoscano: Automated tests: Improve Kernel test for...
marcoscano’s picture

Issue summary: View changes

  • marcoscano committed 8dbd0dc on 8.x-2.x
    Issue #2952008 by marcoscano: Automated tests: Rename legacy kernel...
marcoscano’s picture

Issue summary: View changes
marcoscano’s picture

StatusFileSize
new13.19 KB
marcoscano’s picture

StatusFileSize
new13.57 KB
marcoscano’s picture

StatusFileSize
new14.23 KB

  • marcoscano committed 30dc8c1 on 8.x-2.x
    Issue #2952008 by marcoscano: Automated tests: Extend coverage for...
marcoscano’s picture

Issue summary: View changes
marcoscano’s picture

Issue summary: View changes
StatusFileSize
new25.01 KB
marcoscano’s picture

StatusFileSize
new25.01 KB

Oh I wonder if this is the reason we were having the testbot-only failure in 2954973...
Let's see how about this.

marcoscano’s picture

Aha!

  • marcoscano committed 8c3a634 on 8.x-2.x
    Issue #2952008 by marcoscano: Automated tests: Refactor integration test...
marcoscano’s picture

Issue summary: View changes
marcoscano’s picture

Issue summary: View changes
marcoscano’s picture

StatusFileSize
new3.8 KB

  • marcoscano committed d715930 on 8.x-2.x
    Issue #2952008 by marcoscano: Automated tests: Extend list controller...
marcoscano’s picture

Issue summary: View changes
marcoscano’s picture

StatusFileSize
new16.46 KB
marcoscano’s picture

StatusFileSize
new19.15 KB

  • marcoscano committed 30d9f8d on 8.x-2.x
    Issue #2952008 by marcoscano: Automated tests: Create...
marcoscano’s picture

Issue summary: View changes
marcoscano’s picture

StatusFileSize
new38.63 KB
marcoscano’s picture

StatusFileSize
new40.84 KB

  • marcoscano committed a987cd1 on 8.x-2.x
    Issue #2952008 by marcoscano: Automated tests: Create revisions /...
marcoscano’s picture

Issue summary: View changes
marcoscano’s picture

StatusFileSize
new4.77 KB

  • marcoscano committed cea0bea on 8.x-2.x
    Issue #2952008 by marcoscano: Automated tests: Extend batch update test
    
marcoscano’s picture

Issue summary: View changes
marcoscano’s picture

StatusFileSize
new1.69 KB
marcoscano’s picture

StatusFileSize
new5.6 KB

  • marcoscano committed b8c01d4 on 8.x-2.x
    Issue #2952008 by marcoscano: Automated tests: Improve revisions test...
marcoscano’s picture

Issue summary: View changes
marcoscano’s picture

StatusFileSize
new16.89 KB
marcoscano’s picture

StatusFileSize
new16.86 KB
marcoscano’s picture

StatusFileSize
new17.02 KB
marcoscano’s picture

StatusFileSize
new17 KB
marcoscano’s picture

StatusFileSize
new16.95 KB
marcoscano’s picture

StatusFileSize
new16.98 KB

  • marcoscano committed e6591bd on 8.x-2.x
    Issue #2952008 by marcoscano: Automated tests: Create paragraphs test
    
marcoscano’s picture

Issue summary: View changes
marcoscano’s picture

Status: Active » Fixed

I believe we can call this fixed

Status: Fixed » Closed (fixed)

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