@nevware21/tripwire - v0.1.8
    Preparing search index...

    Function findMatchingTestsAndSuites

    Export filter helpers

    • Applies a filter to a root suite and returns all matching suites and tests. This walks through the entire suite tree and collects suites/tests that pass the filter.

      Parameters

      • rootSuite: ITestSuite

        The root suite to search through

      • filter: ITestFilter

        The filter to apply for determining matches

      Returns IFilterMatchResult

      Object containing arrays of matched suites and tests

      0.2.0

      const suite = createSuite();
      // ... add tests and suites ...

      const filter = createTestIDFilter(["test-1", "test-2"]);
      const result = findMatchingTestsAndSuites(suite, filter);

      console.log(`Found ${result.tests.length} matching tests`);
      console.log(`Found ${result.suites.length} matching suites`);