Testing Build Script Integration in Create React App
This test suite validates core build and test functionality for Create React App across development and production environments. It implements essential smoke tests to verify the reliability of build scripts and testing infrastructure.
Test Coverage Overview
Implementation Analysis
Technical Details
Best Practices Demonstrated
facebook/create-react-app
test/fixtures/jsconfig/index.test.js
'use strict';
const testSetup = require('../__shared__/test-setup');
test('builds in development', async () => {
const { fulfilled } = await testSetup.scripts.start({ smoke: true });
expect(fulfilled).toBe(true);
});
test('builds in production', async () => {
const { fulfilled } = await testSetup.scripts.build();
expect(fulfilled).toBe(true);
});
test('passes tests', async () => {
const { fulfilled } = await testSetup.scripts.test();
expect(fulfilled).toBe(true);
});