Home / Function/ verifyAllTestsPass() — react Function Reference

verifyAllTestsPass() — react Function Reference

Architecture documentation for the verifyAllTestsPass() function in enable-feature-flag.js from the react codebase.

Entity Profile

Dependency Diagram

graph TD
  8b10b33c_dacb_5e2f_27fa_87868d6869cc["verifyAllTestsPass()"]
  fdb06a3a_b735_af93_2b10_31380c21c8b7["enable-feature-flag.js"]
  8b10b33c_dacb_5e2f_27fa_87868d6869cc -->|defined in| fdb06a3a_b735_af93_2b10_31380c21c8b7
  ab68ec04_512e_f89e_9e49_ae73608023f0["main()"]
  ab68ec04_512e_f89e_9e49_ae73608023f0 -->|calls| 8b10b33c_dacb_5e2f_27fa_87868d6869cc
  77ee9936_13cc_cf59_df6b_00e1447cdfc5["runTests()"]
  8b10b33c_dacb_5e2f_27fa_87868d6869cc -->|calls| 77ee9936_13cc_cf59_df6b_00e1447cdfc5
  c83f450b_4a22_69d3_6045_9e51a0d7225e["parseFailingTests()"]
  8b10b33c_dacb_5e2f_27fa_87868d6869cc -->|calls| c83f450b_4a22_69d3_6045_9e51a0d7225e
  style 8b10b33c_dacb_5e2f_27fa_87868d6869cc fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

compiler/scripts/enable-feature-flag.js lines 231–262

function verifyAllTestsPass() {
  console.log('\nRunning final verification (yarn snap)...');

  const {success, output} = runTests();

  // Parse summary line: "N Tests, N Passed, N Failed"
  const summaryMatch = output.match(
    /(\d+)\s+Tests,\s+(\d+)\s+Passed,\s+(\d+)\s+Failed/
  );

  if (summaryMatch) {
    const [, total, passed, failed] = summaryMatch;
    console.log(
      `\nTest Results: ${total} Tests, ${passed} Passed, ${failed} Failed`
    );

    if (failed === '0') {
      console.log('All tests passed!');
      return true;
    } else {
      console.error(`${failed} tests still failing`);
      const failingTests = parseFailingTests(output);
      if (failingTests.length > 0) {
        console.error('\nFailing tests:');
        failingTests.forEach(test => console.error(`  - ${test}`));
      }
      return false;
    }
  }

  return success;
}

Domain

Subdomains

Called By

Frequently Asked Questions

What does verifyAllTestsPass() do?
verifyAllTestsPass() is a function in the react codebase, defined in compiler/scripts/enable-feature-flag.js.
Where is verifyAllTestsPass() defined?
verifyAllTestsPass() is defined in compiler/scripts/enable-feature-flag.js at line 231.
What does verifyAllTestsPass() call?
verifyAllTestsPass() calls 2 function(s): parseFailingTests, runTests.
What calls verifyAllTestsPass()?
verifyAllTestsPass() is called by 1 function(s): main.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free