Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions ietf/mailinglists/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,13 @@ def test_groups(self):


def test_nonwg(self):
groups = list()
groups.append(GroupFactory(type_id='wg', acronym='mars', list_archive='https://ietf.org/mars'))
groups.append(GroupFactory(type_id='wg', acronym='ames', state_id='conclude', list_archive='https://ietf.org/ames'))
groups.append(GroupFactory(type_id='wg', acronym='newstuff', state_id='bof', list_archive='https://ietf.org/newstuff'))
groups.append(GroupFactory(type_id='rg', acronym='research', list_archive='https://irtf.org/research'))
lists = ListFactory.create_batch(7)

url = urlreverse("ietf.mailinglists.views.nonwg")

r = self.client.get(url)
Expand All @@ -43,3 +49,6 @@ def test_nonwg(self):
else:
self.assertNotContains(r, l.name, html=True)
self.assertNotContains(r, l.description, html=True)

for g in groups:
self.assertNotContains(r, g.acronym, html=True)
4 changes: 2 additions & 2 deletions ietf/mailinglists/views.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright The IETF Trust 2007, All Rights Reserved
# Copyright The IETF Trust 2007-2022, All Rights Reserved

import re

Expand All @@ -15,7 +15,7 @@ def groups(request):
return render(request, "mailinglists/group_archives.html", { "groups": groups } )

def nonwg(request):
groups = Group.objects.filter(type__features__acts_like_wg=True).exclude(state__in=['bof', 'conclude']).order_by("acronym")
groups = Group.objects.filter(type__features__acts_like_wg=True).exclude(state__in=['bof']).order_by("acronym")

#urls = [ g.list_archive for g in groups if '.ietf.org' in g.list_archive ]

Expand Down