Giter Site home page Giter Site logo

mib-users's Introduction

My message in A Bottle - Users microservice

This is the source code of Message in a Bottle application, self project of Advanced Software Engineering course, University of Pisa.

CircleCI codecov

Team info

  • The squad id is 4
  • The team leader is Davide Fiorini

Members

Name and Surname Email
Alessio Matricardi [email protected]
Davide Fiorini [email protected]
Gianmarco Manfredonia [email protected]
Marco Parti [email protected]
Riccardo Bonini [email protected]
Riccardo Gallo [email protected]

Instructions

Initialization

To setup the project initially you have to run these commands inside the project's root.

virtualenv -p python3 venv

source venv/bin/activate

pip install -r requirements.dev.txt

Run the project

To run the project you have to setup the flask environment, you can do it by executing the following commands:

cp env_file_example env_file
cp env_file_example .env
export FLASK_ENV=development
flask run

Flask routes

To show the primary routes of flask application you can issue the following command:

flask routes

The default swagger-ui interface is available on /ui

Application Environments

The available environments are:

  • debug
  • development
  • testing
  • production

If you want to run the application with development environment you can run the run.sh script.

Note: if you use docker-compose up you are going to startup a production ready microservice, hence postgres will be used as default database and gunicorn will serve your application.

If you are developing application and you want to have the debug tools, you can start application locally (without docker-compose) by executing bash run.sh.

Run tests

To run all the tests, execute the following command:

python -m pytest

You can also specify one or more specific test files, in order to run only those specific tests. In case you also want to see the overall coverage of the tests, execute the following command:

python -m pytest --cov=mib

In order to know what are the lines of codes which are not covered by the tests, execute the command:

python -m pytest --cov-report term-missing

Conventions

  • Name of files must be snake_cased
  • Name of methods, properties, variables must be snake_cased
  • Name of classes must be PascalCased
  • Name of constants must be UPPERCASE
  • The class name of managers must be in the format <BeanName>Manager

Future implementations


mib-users's People

Contributors

alessiomatricardi avatar dependabot[bot] avatar gmanfry avatar m4r-kus avatar rjknet avatar

Watchers

 avatar

Forkers

rjknet

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.