Do not show availability for currently-selected add-on

This commit is contained in:
Raphael Michel
2019-11-04 09:55:00 +01:00
parent 47cf019079
commit d15e37d93e
3 changed files with 21 additions and 13 deletions

View File

@@ -2,7 +2,7 @@ from bs4 import BeautifulSoup
from django.test import TestCase
class SoupTest(TestCase):
class SoupTestMixin:
def get_doc(self, *args, **kwargs):
response = self.client.get(*args, **kwargs)
@@ -17,6 +17,10 @@ class SoupTest(TestCase):
return BeautifulSoup(response.content, "lxml")
class SoupTest(SoupTestMixin, TestCase):
pass
def extract_form_fields(soup):
"""
Turn a BeautifulSoup form in to a dict of fields and default values