.. _developer-guide/project-structure: Project Structure ================= The Ibutsu project is divided into 3 main components: * API client * pytest plugin * Server API Client ---------- The API client is an autogenerated codebase, which uses the `OpenAPI Generator `_ to generate the client from the API. To regenerate the client, run the regeneration script in the root of the repository: .. code:: shell ./regenerate-client.sh --commit --push --delete path/to/openapi.yaml To understand what the options do, just use the ``--help`` option: .. code-block:: shell ./regenerate-client.sh --help Usage: regenerate-client.sh [-h|--help] [-c|--commit] [-p|--push] [-d|--delete] OPENAPI_FILE optional arguments: -h, --help show this help message -c, --commit create a new branch and commit all the changes -p, --push push the branch up to origin after commit -d, --delete delete the branch after pushing pytest Plugin ------------- The pytest plugin simply uses the API client to send test results from a pytest run to an Ibutsu server. The plugin can be installed from PyPI via pip: .. code-block:: shell pip install pytest-ibutsu Of course if you want to develop this, you're not going to want to install it from PyPI, so let's rather do an editable installation: .. code-block:: shell pip install -e . Server ------ The server is further divided into two separate apps: * Frontend * Backend Frontend ~~~~~~~~ The frontend for the server is written in `ES6 `_ and `React `_, and uses `Yarn `_ to manage dependencies. Backend ~~~~~~~ The backend of the server is made up of 5 parts: * The API itself, written in Python/Flask/Connexion * The task worker, which runs async tasks, written with Celery * The task monitor, which keeps tabs on task failures * A `MongoDB `_ instance, which is the database * A `Redis `_ instance, which is used by the task worker