- Clone or download the repository.
- If you want to use virtual environment run
virtualenv food_manager_env --python=python3
. and activate environment. food_manager_env/bin/activate
. - Browse to the project root directory and run
pip install .
to install foodManager and its dependecies. - Set environment variable:
export FLASK_APP=foodManager
. - Populated database
foodManager/dev.db
is supplied in the repo. But if you want to initialize and populate it, removedev.db
first. Then, initialize and populate database:flask init-db
andflask testgen
. - Serve flask app:
flask run
.
Unit and functional tests reside in foodManager/tests
.
To run these tests:
- Make sure you have pytest installed. If you don't, run
pip install pytest
- Navigate to project root and run
pytest tests/
.
In case the above instructions give ModuleNotFoundError, you can try the following:
- Install pytest inside the environment:
pip install pytest
while the environment is activated. - Inside the project root, run
python -m pytest tests/
Make sure you have node.js installed.
- clone or download the repository.
cd
toclient
foldernpm install
npm start
(starts the development server on port 3000)
cd
toclient
foldernpm run docz:dev
(documentation server runs on port 3001)
- Teemu Varsala, [email protected]
- Arttu Käyrä, [email protected]
Remember to include all required documentation and HOWTOs, including how to create and populate the database, how to run and test the API, the url to the entrypoint and instructions on how to setup and run the client