Skip to content

jovanovicdanilo7/m01.devops.training-python

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Demo Project for Python and CI/CD

This is a demo Python project designed to showcase a CI/CD pipeline for Python projects. It includes:

  • Unit tests with pytest.
  • Integration tests.
  • Linting with flake8 (see the lint target in the Makefile).
  • A build step to package the project.

Getting Started

It's recommended to create a virtualenv first:

python3 -m venv venv
source venv/bin/activate
  1. Install dependencies:

    pip install -r requirements.txt
  2. Run tests:

    make test
    make lint
  3. Build a release wheel:

    make build

Project structure

/
├── .gitignore
├── Makefile
├── README.md
├── requirements.txt
├── setup.py
├── demo_project
│   ├── __init__.py
│   └── calculator.py
└── tests
    ├── __init__.py
    ├── test_calculator_integration.py
    └── test_calculator_unit.py

Steps

  1. Fork this repository.
  2. Clone the repository to your machine.
  3. Add the repository in your Semaphore account
  4. Choose "I will use existing configuration"
  5. Make a small change (e.g. README.md file add a blank line)
  6. Commit and push the change to your repository
  7. Discuss why the pipeline is failing
  8. Fix the pipeline

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 88.4%
  • Makefile 11.6%