The backend was bootstrapped with django-admin startproject app
.
测试入口:各文件夹中的 tests.py 推荐各功能模块自己实现测试模块,例:新建 funcAtests.py (pytest写法),在此目录的 tests.py 中import funcAtests。
示例 https://gitlab.secoder.net/example/monolithic-example/-/blob/master/meeting/tests.py
frame from: https://gitlab.secoder.net/example/monolithic-example
- app Core settings for Django.
- meeting Created by
python manage.py startapp meeting
. - manage.py settings for Django.
==the following files should remain unmodified==
- pytest.ini Configuration for pytest.
- requirements.txt Package manager with
pip
. - requirements_dev.txt Package manager with
pip
, including extra tools for development. - Dockerfile configure our docker image to run, ' EXPOSE 80 ' set the port we can use
- .gitlab-ci.yml configure our CI/CD settings
- sonar-project.properties configure sonar
python manage.py runserver
Run this project in development mode.python manage.py makemigrations
Detect changes in data schema.python manage.py migrate
Apply migrations to current database.pytest
Test.pylint --load-plugins=pylint_django app meeting
Advanced PEP8 checking.
docker build -t something .
docker run --rm something