File: pytest-8.4.patch

package info (click to toggle)
python-setoptconf 0.3.0-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 252 kB
  • sloc: python: 1,427; sh: 7; makefile: 5
file content (52 lines) | stat: -rw-r--r-- 1,883 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
--- a/test/test_datatypes.py
+++ b/test/test_datatypes.py
@@ -59,9 +59,9 @@
 
 def test_simple_sanitization():
     for datatype, in_value, out_value in GOOD_SIMPLE_VALUES:
-        yield check_good_value, datatype, in_value, out_value
+        check_good_value(datatype, in_value, out_value)
     for datatype, in_value in BAD_SIMPLE_VALUES:
-        yield check_bad_value, datatype, in_value
+        check_bad_value(datatype, in_value)
 
 def check_good_value(datatype, in_value, out_value):
     dt = datatype()
@@ -102,9 +102,9 @@
 
 def test_list_sanitization():
     for subtype, in_value, out_value in GOOD_LIST_VALUES:
-        yield check_good_list_value, subtype, in_value, out_value
+        check_good_list_value(subtype, in_value, out_value)
     for subtype, in_value, exc in BAD_LIST_VALUES:
-        yield check_bad_list_value, subtype, in_value, exc
+        check_bad_list_value(subtype, in_value, exc)
 
 def check_good_list_value(subtype, in_value, out_value):
     dt = soc.List(subtype)
@@ -139,9 +139,9 @@
 
 def test_choice_sanitization():
     for subtype, choices, value in GOOD_CHOICE_VALUES:
-        yield check_good_choice_value, subtype, choices, value
+        check_good_choice_value(subtype, choices, value)
     for subtype, choices, value, exc in BAD_CHOICE_VALUES:
-        yield check_bad_choice_value, subtype, choices, value, exc
+        check_bad_choice_value(subtype, choices, value, exc)
 
 def check_good_choice_value(subtype, choices, value):
     dt = soc.Choice(choices, subtype)
--- a/test/test_settings.py
+++ b/test/test_settings.py
@@ -21,9 +21,9 @@
 
 def test_name():
     for name in GOOD_NAMES:
-        yield check_good_name, name
+        check_good_name(name)
     for name in BAD_NAMES:
-        yield check_bad_name, name
+        check_bad_name(name)
 
 def check_good_name(name):
     setting = soc.StringSetting(name)