Our Commitment to Open Source can be found here
- Fork this repository to your own GitHub account and then clone it to your local device.
- Install yarn:
npm install -g yarn - Install the dependencies:
yarn - Run
yarn run devto build and watch for code changes
Running all tests:
yarn testonly
Running a specific test suite inside of the test/integration directory:
yarn testonly --testPathPattern "production"
Running just one test in the production test suite:
yarn testonly --testPathPattern "production" -t "should allow etag header support"
./node_modules/.bin/next ./test/integration/basic
Because of the way Node.js resolves modules the easiest way to test your own application is copying it into the test directory.
cp -r yourapp <next.js directory>/test/integration/yourapp
Make sure you remove react react-dom and next from test/integration/yourapp/node_modules as otherwise they will be overwritten.
rm -rf <next.js directory>/test/integration/yourapp/{react,react-dom,next,next-server}Then run your app using:
./node_modules/.bin/next ./test/integration/yourapp