Skip to content
Snippets Groups Projects
Commit 28ff57df authored by Martin Burchell's avatar Martin Burchell
Browse files

Added simple test for term name in term count

parent ea8014f8
Branches
No related tags found
No related merge requests found
...@@ -75,3 +75,15 @@ def test_term_count_only_contains_terms_in_taxonomy(questions_category, ...@@ -75,3 +75,15 @@ def test_term_count_only_contains_terms_in_taxonomy(questions_category,
assert updates['name'] in names assert updates['name'] in names
assert monrovia['name'] not in names assert monrovia['name'] not in names
@pytest.mark.django_db
def test_term_count_contains_taxonomy_term_name(questions_category):
origin1 = create_item(body="What was the caused of ebola outbreak in liberia?").data
origins = add_term(taxonomy=questions_category['slug'], name="Test Origins").data
categorize_item(origin1, origins)
terms = get_term_count(questions_category).data
[name] = [term['name'] for term in terms]
assert origins['name'] == name
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment