Example #1
0
 def limits_to_five_items():
     assert (quoted_or_list(["A", "B", "C", "D", "E",
                             "F"]) == "'A', 'B', 'C', 'D' or 'E'")
Example #2
0
 def does_not_accept_an_empty_list():
     with raises(TypeError):
         quoted_or_list([])
Example #3
0
 def returns_comma_separated_many_item_list():
     assert quoted_or_list(["A", "B", "C"]) == "'A', 'B' or 'C'"
Example #4
0
 def returns_two_item_list():
     assert quoted_or_list(["A", "B"]) == "'A' or 'B'"
Example #5
0
 def returns_single_quoted_item():
     assert quoted_or_list(["A"]) == "'A'"
Example #6
0
 def limits_to_five_items():
     assert quoted_or_list(['A', 'B', 'C', 'D', 'E',
                            'F']) == "'A', 'B', 'C', 'D' or 'E'"
Example #7
0
 def returns_two_item_list():
     assert quoted_or_list(['A', 'B']) == "'A' or 'B'"