Is there a particular directory structure used for TDD in Python?
Tutorials talk about the content of the tests, but not where to place them
From poking around Python Koans, suspect its something like:
/project/main_program.py # This has main method, starts program /project/classes/<many classes>.py /project/main_test.py # This simply directs unittest onto tests, can use parameters fed to it to customise tests for environment /project/tests/<many tests>.py # to run tests, type "python -m unittest main_test.py" (into a terminal) # to run program, type "python main_program.py"
Am I doing this right? Is there a good guide which teaches the directory hierarchy for TDD? I heard that having mixed files of code and tests is bad.
- Are there any good online tutorials to TDD for an experienced programmer who is new to testing? # A coding dojo? hmm... Perhaps I'll start a coding dojo website...
- http://onlamp.com/pub/a/python/2004/12/02/tdd_pyunit.html #Shows mixed files
- http://www.youtube.com/watch?v=sD6qzJNQEpE #As great as pyTDDmon looks, I'd like to understand the basics first =) also thats a mixed file
- http://www.slideshare.net/Skud/test-driven-development-tutorial #explains "design test implement test repeat" only..
- http://blog.cerris.com/category/django-tdd/ #Still no help...