This page describes how to setup the project on your computer for local development.
For Windows users, there (will be) a dedicated quick-start guide.
First, you should create a folder for Bemuse development:
mkdir Bemuse cd Bemuse
Then, clone the Bemuse repository and music repository:
git clone firstname.lastname@example.org:bemusic/bemuse.git git clone email@example.com:bemusic/music.git
After these repository has been cloned,
cd into the Bemuse repository:
Install the project’s dependencies:
When it finishes installing, start the development server:
The game should be accessible at
To run unit tests, go to
We measure the code coverage to make sure that most part of our code is covered by some test. This helps us be more confident in modifying our code.
To turn on the coverage mode, start the server with the
BEMUSE_COV environment variable set to
BEMUSE_COV=true npm start
Then run the unit tests.
After the unit tests are run, the coverage report will be generated.
They can be viewed at
To build the source code into a static web application, run:
npm run build
The built files will reside in the
You can run tests from the command line by running:
This will effectively
- build Bemuse with coverage mode turned on,
- start a web server,
- start a web browser and navigate to the test page, effectively running the tests,
- collect the results and code coverage and write reports.