Skip to content

vaqm2/tdd

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

TDD Practice Repository

This repository is a practice resource for learning Test Driven Development (TDD) principles using the Yatzy game as the implementation example.

About This Project

The Yatzy game serves as the practical foundation for understanding and applying TDD concepts. Through implementing the game's scoring and logic, you'll learn how to write tests first and develop features incrementally.

Dependencies

  • Python 3.x - The programming language used
  • pytest - Testing framework for writing and running tests

Testing Methodology

This project uses pytest for all testing. The development approach follows TDD principles:

  1. Write a test first (Red phase)
  2. Write minimal code to pass the test (Green phase)
  3. Refactor the code for clarity and maintainability (Refactor phase)

Running Tests

To run all tests:

pytest

To run tests with verbose output:

pytest -v

To run tests with coverage report:

pytest --cov=yatzy

Project Structure

  • yatzy/ - Main implementation of the Yatzy game
  • tests/ - Test suite validating the Yatzy implementation

Getting Started

  1. Clone the repository
  2. Install dependencies: pip install pytest
  3. Run the tests: pytest
  4. Explore the code and tests to understand the TDD approach used

About

Exercises in test driven development

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages