start testing
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
import pytest
|
||||
#from django.contrib.auth.models import User
|
||||
from django.urls import reverse
|
||||
|
||||
@pytest.fixture
|
||||
def create_superuser(db, django_user_model):
|
||||
return django_user_model.objects.create_superuser("admin", "ross@xkjq.uk", "adminpassword")
|
||||
|
||||
def test_index(client, create_superuser):
|
||||
client.login(username="admin", password="adminpassword")
|
||||
response = client.get(reverse('rapids:index'))
|
||||
assert response.status_code == 200
|
||||
Reference in New Issue
Block a user