Quality Control for Python Applications
Improve the maintainability and quality of your code. Attendees will become familiar with code modularity and organization principles, as well as quality control methods such as automated testing and continuous integration.
Prerequisites
Required Software:
- GitHub Desktop (requires a GitHub account)
- VS Code Text Editor
- Anaconda
- Command Line Application (Terminal on Mac, Git Bash on Windows)
Attendees should be familiar with Python Development Tools and Version Control before attempting this workshop.
Parts 1 and 2: Code Maintenance and Organization
Learning Objectives:
- Translate code from a Python notebook into a local development repository.
- Identify areas in code that can be simplified for improved readability and maintainability.
- Refactor code by simplifying complex logic and removing duplication.
- Discuss code organization concepts such as the single responsibility principle, and the DRY principle.
- Organize code into modules to enhance scalability and maintainability, and practice importing code across multiple files.
- Use automated tools such as Code Climate to perform automated assessments of code complexity and maintainability.
Part 3: Code Verification and Testing
Learning Objectives:
- Discuss the benefits of implementing automated tests in a software development project.
- Write automated tests for Python applications.
- Execute automated tests locally using the
pytestpackage. - Execute automated tests on a Continuous Integration server, using a GitHub Actions workflow.