Merge pull request #104 from cisagov/sspj/django-tests

Add testing to the CI pipeline
This commit is contained in:
Seamus Johnston 2022-09-08 13:48:51 +00:00 committed by GitHub
commit d2da8d1d8f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 54 additions and 0 deletions

View file

View file

View file

@ -0,0 +1,11 @@
from django.test import Client, TestCase
class HealthTest(TestCase):
def setUp(self):
self.client = Client()
def test_health_check_endpoint(self):
response = self.client.get("/health/")
self.assertEqual(response.status_code, 200)
self.assertEqual(response.content, b"OK")