Jessica Walkenhorst commited on
Commit
6295a87
1 Parent(s): 6349813

Feature/add test for attendancelist update (#2)

Browse files
Files changed (1) hide show
  1. tests/test_attendancelist.py +13 -1
tests/test_attendancelist.py CHANGED
@@ -1,4 +1,4 @@
1
- from maorganizer.datawrangling import Person, Attendancelist
2
 
3
 
4
  def test_attendancelist_finds_person_by_substring():
@@ -20,3 +20,15 @@ def test_find_multiple_finds_alls():
20
  Person(name="Ford Prefix"): {Person(name="Ford Prefix")},
21
  Person(name="Zaphod"): {Person(name="Zaphod Beeblebrox")},
22
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from maorganizer.datawrangling import Attendancelist, Person
2
 
3
 
4
  def test_attendancelist_finds_person_by_substring():
 
20
  Person(name="Ford Prefix"): {Person(name="Ford Prefix")},
21
  Person(name="Zaphod"): {Person(name="Zaphod Beeblebrox")},
22
  }
23
+
24
+
25
+ def test_attendance_list_updates_correctly():
26
+ assert Attendancelist({Person("zaphod beeblebrox"), Person("ford prefix")}).update(
27
+ Attendancelist(
28
+ {
29
+ Person("zaphod beeblebrox"),
30
+ Person("ford prefix"),
31
+ Person("lord crawfish"),
32
+ }
33
+ )
34
+ ) == Attendancelist(participants={Person("lord crawfish")})