Skip to content

CGnal/python-unittests-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

python-unittests-example

A simple Python project for introducing unit testing

Setup

Setup project dependencies running

pip install -r requirements.txt

Content

The project is a helper content to the course presentation. It includes example python scripts and an exercise to be completed.

Exercise

The fizzbuzz() function located in src/fizzbuzz.py file, can be tested by feeding a few different numbers and asserting that the correct response is given for each one. To keep things nicely organized, separate unit tests can be written to test for "Fizz", "Buzz" and "FizzBuzz" numbers.

Pull your repository in your local machine, and complete the test cases in the file tests/test_fizzbuzz.py.

Create a working branch, and complete the task.

Please feel free to add other tests than the ones in the skeleton proposed.

After having completed the task open a Pull Request on the remote repo.

About

No description, website, or topics provided.

Resources

License

Stars

0 stars

Watchers

3 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages