Testing Bootstrap-Sass Build Integration in Create-React-App
This test suite validates the build process for a React application using Bootstrap with Sass integration. It focuses on verifying successful builds in both development and production environments, implementing essential smoke tests for the build pipeline.
Test Coverage Overview
Implementation Analysis
Technical Details
Best Practices Demonstrated
facebook/create-react-app
test/fixtures/boostrap-sass/index.test.js
'use strict';
const testSetup = require('../__shared__/test-setup');
if (testSetup.isLocal) {
// TODO: make this work locally
test('skipped locally', () => {});
} else {
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);
});
}