Adjust tests to match changes to permissions made in through the admin. These need to use the data rather than the code. See #3393. Commit ready for merge.

- Legacy-Id: 19311
This commit is contained in:
Robert Sparks 2021-09-01 14:30:09 +00:00
parent 847f37dbf7
commit 4240ce088e
2 changed files with 2 additions and 2 deletions

View file

@ -280,7 +280,7 @@ class GroupPagesTests(TestCase):
'rg' : ['secretary','irtf-chair'],
'ag' : ['secretary', 'ad' ],
'rag' : ['secretary', 'irtf-chair'],
'team' : ['secretary',], # The code currently doesn't let ads edit teams or directorates. Maybe it should.
'team' : ['secretary' , 'ad'],
'dir' : ['secretary',],
'review' : ['secretary',],
'program' : ['secretary', 'iab-member'],

View file

@ -155,7 +155,7 @@ class InterimMeetingModelForm(forms.ModelForm):
return # don't reduce group options
q_objects = Q()
if has_role(self.user, "Area Director"):
q_objects.add(Q(type__in=["wg", "ag"], state__in=("active", "proposed", "bof")), Q.OR)
q_objects.add(Q(type__in=["wg", "ag", "team"], state__in=("active", "proposed", "bof")), Q.OR)
if has_role(self.user, "IRTF Chair"):
q_objects.add(Q(type__in=["rg", "rag"], state__in=("active", "proposed")), Q.OR)
if has_role(self.user, "WG Chair"):