Skip to content
This repository has been archived by the owner on Sep 3, 2024. It is now read-only.

Improve test coverage #1

Open
2 of 3 tasks
chris48s opened this issue Oct 1, 2017 · 0 comments
Open
2 of 3 tasks

Improve test coverage #1

chris48s opened this issue Oct 1, 2017 · 0 comments

Comments

@chris48s
Copy link
Member

chris48s commented Oct 1, 2017

I've started adding some tests for this package but our coverage level is still low. There's a few problems to tackle:

  • In order to write tests for https://github.com/DemocracyClub/dc_signup_form/blob/master/dc_signup_form/views.py we need to create a stub django project for the tests to run in. With the minimal stub app defined in https://github.com/DemocracyClub/dc_signup_form/blob/master/run_tests.py it falls over as soon as you try to render a template because it is expecting stuff like static files, base.html template, dc_base_theme, context processors + so on to exist, and they don't. done in 07d5b1f

  • At the moment the tests run against whatever postgres version is current on travis, but the code contains special cases to support Postgres < 9.4 and >= 9.4 so the build config should declare environments which allow us run the tests on multiple postgres versions to properly test that support. added in 0c784fa

  • Quite a lot of the untested code is making calls to external APIs so there is some work do on mocking out the interactions with other services (and perhaps some refactoring to make that a bit easier to do)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant