This is a React-based character generator for Shadowrun 2nd and 3rd editions. It allows users to create characters using either the Priority or Point Buy methods, with support for various character types including magical users, deckers, and otaku.
npm install
npm start
The application uses Jest for testing. To run the tests:
# Run all tests
npm test -- --watchAll=false
# Run tests with coverage report
npm test -- --watchAll=false --coverage
# Or use the provided script
./run-tests.sh
Tests are organized to match the component structure of the application:
App.test.js
- Tests for the main App componentcomponents/*.test.js
- Tests for individual components
The tests currently focus on basic component rendering to ensure the application structure is sound. Some components have more detailed tests that verify:
- Component rendering
- Basic functionality
Some tests may fail due to the complex nature of the components and their interdependencies. The test suite is a work in progress and will be expanded over time.
When adding new tests, make sure to:
- Mock any external dependencies
- Provide complete mock data for components that expect specific props
- Use the
--legacy-peer-deps
flag when installing new testing dependencies to avoid conflicts