TDD comes first. We've gone ahead and written a bunch of tests to test the creation of our models in the registry database. We test this by checking the count before and after an instance of the model is created. If the count differs, it means the record was written in the respective database table.
How can this be manually tested?
Pull for changes from this branch
Export the following env variables for the application instance:
→ export APP_SETTINGS="development"
→ export DATABASE_URL=postgresql://localhost:5432/registry
Ensure you've created the postgres database calling it registry. If not, create one by using the postgres utility
→ createdb regisitry
Run tests using this simple command
→ python manage.py test
What does this PR do?
It defines a test suite for the registry models
Description?
TDD comes first. We've gone ahead and written a bunch of tests to test the creation of our models in the registry database. We test this by checking the count before and after an instance of the model is created. If the count differs, it means the record was written in the respective database table.
How can this be manually tested?
export APP_SETTINGS="development"
→export DATABASE_URL=postgresql://localhost:5432/registry
createdb regisitry
python manage.py test
Relevant pivotal tracker stories?
N/A