LearnNewsExamplesServices
Frontmatter
id9466
titleTreeGrid Big Data Demo: Create E2E Tests
stateClosed
labels
enhancementaitesting
assigneestobiu
createdAtMar 13, 2026, 12:09 PM
updatedAtMar 13, 2026, 2:29 PM
githubUrlhttps://github.com/neomjs/neo/issues/9466
authortobiu
commentsCount1
parentIssue9461
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtMar 13, 2026, 2:29 PM

TreeGrid Big Data Demo: Create E2E Tests

Closed v12.1.0 enhancementaitesting
tobiu
tobiu commented on Mar 13, 2026, 12:09 PM

Goal

Create comprehensive end-to-end (E2E) tests for the new TreeGrid Big Data demo using Playwright to ensure performance, stability, and correctness of core interactions (expand/collapse, scrolling, filtering) under heavy data loads.

Inspiration & Context

  • test/playwright/e2e/GridTree.spec.mjs: Serves as a template for tree-specific interactions (expand/collapse, node visibility, hierarchical sorting).
  • test/playwright/e2e/GridScrollBenchmark.spec.mjs: Serves as a template for performance testing, handling large scrolling areas, and isolating layout jank.

Implementation Steps

  1. Create Test File: Create a new file test/playwright/e2e/GridTreeBigData.spec.mjs.
  2. Basic Initialization & Load Test:
    • Navigate to /examples/grid/treeBigData/index.html.
    • Wait for the grid to render its initial rows.
    • Verify that the ControlsContainer is fully initialized.
  3. Interaction Testing (Expand/Collapse):
    • Target a root folder and trigger an expansion.
    • Verify that the correct number of child rows are injected into the DOM.
    • Verify that the bulk Expand All and Collapse All buttons in the ControlsContainer function correctly without crashing the main thread.
  4. Performance/Scroll Testing:
    • Implement vertical and horizontal scroll tests similar to the GridScrollBenchmark.
    • Ensure smooth scrolling (native scroll) across a high volume of rows and columns.
  5. Filtering Validation:
    • Apply a filter via the ControlsContainer (e.g., firstname).
    • Assert that the TreeStore correctly filters the data and that parent folders of matching children remain visible.
tobiu added the enhancement label on Mar 13, 2026, 12:09 PM
tobiu added the ai label on Mar 13, 2026, 12:09 PM
tobiu added the testing label on Mar 13, 2026, 12:09 PM
tobiu assigned to @tobiu on Mar 13, 2026, 12:09 PM
tobiu added parent issue #9461 on Mar 13, 2026, 12:09 PM
tobiu referenced in commit cae1d2a - "#9466 initial e2e setup" on Mar 13, 2026, 1:45 PM
tobiu referenced in commit 0d8bca4 - "test(E2E): Rewrite GridTreeBigData to handle virtual scroll metrics (#9466) on Mar 13, 2026, 2:28 PM
tobiu
tobiu Mar 13, 2026, 2:29 PM

Input from Gemini 3.1 Pro:

✦ I have committed and pushed the updated E2E tests for the TreeGrid Big Data example.

  • Changed the test logic to work robustly with virtual scrolling by looking for specific data-record-id changes and structural shifts, rather than exact count assertions for expanded/filtered states.
  • Handled the sliding ControlsContainer toggling to ensure the controls panel does not obstruct mouse events or go out of bounds.
  • Augmented the Filtering test to evaluate both positive matches (forcing auto-expansion) and invalid matches (forcing 0 results), testing the persistence of expansion states after clearing the filter.
  • Applied the Knowledge Base Enhancement Strategy by adding architectural comments to TreeStore.#rebuildKeysAndCount() and the E2E test file itself to guide future tests on virtual scrollers.
tobiu closed this issue on Mar 13, 2026, 2:29 PM