Skip to content

Commit

Permalink
test: add tests for public views
Browse files Browse the repository at this point in the history
  • Loading branch information
danihodovic committed May 21, 2024
1 parent feda284 commit 5073fa7
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion tests/tests.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,22 @@
import pytest
from django.urls import reverse
from django.urls import reverse, reverse_lazy

pytestmark = pytest.mark.django_db


@pytest.mark.parametrize(
"url",
[
reverse_lazy("account_login"),
reverse_lazy("account_reset_password"),
reverse_lazy("account_email_verification_sent"),
],
)
def test_200_all_urls(url, client):
res = client.get(url)
assert res.status_code == 200


def test_works_without_socialaccount_app(settings, client):
settings.INSTALLED_APPS = [
app for app in settings.INSTALLED_APPS if app != "allauth.socialaccount"
Expand Down

0 comments on commit 5073fa7

Please sign in to comment.