@@ -4,110 +4,158 @@ PYTEST ?= python3 -m pytest
4
4
# pytest-xdist is installed)
5
5
PYTEST_ARGS ?=
6
6
7
+ # Will be appended at the end of the -m argument to pytest
8
+ EXTRA_MARKERS ?=
9
+
7
10
# Will be appended at the end of the -k argument to pytest
8
11
EXTRA_SELECTORS ?=
9
12
10
- BAHAMUT_SELECTORS := \
13
+ BAHAMUT_MARKERS := \
11
14
not implementation-specific \
12
15
and not deprecated \
13
16
and not strict \
14
- and not IRCv3 \
17
+ and not IRCv3
18
+ BAHAMUT_SELECTORS := \
19
+ (foo or not foo) \
15
20
$(EXTRA_SELECTORS )
16
21
17
- CHARYBDIS_SELECTORS := \
22
+ CHARYBDIS_MARKERS := \
18
23
not implementation-specific \
19
24
and not deprecated \
20
25
and not strict \
26
+ $(EXTRA_MARKERS )
27
+ CHARYBDIS_SELECTORS := \
28
+ (foo or not foo) \
21
29
$(EXTRA_SELECTORS )
22
30
23
- ERGO_SELECTORS := \
31
+ ERGO_MARKERS := \
24
32
(Ergo or not implementation-specific) \
25
33
and not deprecated \
34
+ $(EXTRA_MARKERS )
35
+ ERGO_SELECTORS := \
36
+ (foo or not foo) \
26
37
$(EXTRA_SELECTORS )
27
38
28
- HYBRID_SELECTORS := \
39
+ HYBRID_MARKERS := \
29
40
not implementation-specific \
30
41
and not deprecated \
42
+ $(EXTRA_MARKERS )
43
+ HYBRID_SELECTORS := \
44
+ (foo or not foo) \
31
45
$(EXTRA_SELECTORS )
32
46
33
- INSPIRCD_SELECTORS := \
47
+ INSPIRCD_MARKERS := \
34
48
not implementation-specific \
35
49
and not deprecated \
36
50
and not strict \
51
+ $(EXTRA_MARKERS )
52
+ INSPIRCD_SELECTORS := \
53
+ (foo or not foo) \
37
54
$(EXTRA_SELECTORS )
38
55
39
- IRCU2_SELECTORS := \
56
+ IRCU2_MARKERS := \
40
57
not implementation-specific \
41
58
and not deprecated \
42
59
and not strict \
60
+ and not IRCv3 \
61
+ $(EXTRA_MARKERS )
62
+ IRCU2_SELECTORS := \
63
+ (foo or not foo) \
43
64
$(EXTRA_SELECTORS )
44
65
45
- NEFARIOUS_SELECTORS := \
66
+ NEFARIOUS_MARKERS := \
46
67
not implementation-specific \
47
68
and not deprecated \
48
69
and not strict \
70
+ $(EXTRA_MARKERS )
71
+ NEFARIOUS_SELECTORS := \
72
+ (foo or not foo) \
49
73
$(EXTRA_SELECTORS )
50
74
51
- SNIRCD_SELECTORS := \
75
+ SNIRCD_MARKERS := \
52
76
not implementation-specific \
53
77
and not deprecated \
54
78
and not strict \
79
+ and not IRCv3 \
80
+ $(EXTRA_MARKERS )
81
+ SNIRCD_SELECTORS := \
82
+ (foo or not foo) \
55
83
$(EXTRA_SELECTORS )
56
84
57
- IRC2_SELECTORS := \
85
+ IRC2_MARKERS := \
58
86
not implementation-specific \
59
87
and not deprecated \
60
88
and not strict \
89
+ and not IRCv3 \
90
+ $(EXTRA_MARKERS )
91
+ IRC2_SELECTORS := \
92
+ (foo or not foo) \
61
93
$(EXTRA_SELECTORS )
62
94
63
- MAMMON_SELECTORS := \
95
+ MAMMON_MARKERS := \
64
96
not implementation-specific \
65
97
and not deprecated \
66
98
and not strict \
99
+ $(EXTRA_MARKERS )
100
+ MAMMON_SELECTORS := \
101
+ (foo or not foo) \
67
102
$(EXTRA_SELECTORS )
68
103
69
- NGIRCD_SELECTORS := \
104
+ NGIRCD_MARKERS := \
70
105
not implementation-specific \
71
106
and not deprecated \
72
107
and not strict \
108
+ $(EXTRA_MARKERS )
109
+ NGIRCD_SELECTORS := \
110
+ (foo or not foo) \
73
111
$(EXTRA_SELECTORS )
74
112
75
- PLEXUS4_SELECTORS := \
113
+ PLEXUS4_MARKERS := \
76
114
not implementation-specific \
77
115
and not deprecated \
116
+ $(EXTRA_MARKERS )
117
+ PLEXUS4_SELECTORS := \
118
+ (foo or not foo) \
78
119
$(EXTRA_SELECTORS )
79
120
80
- # Limnoria can actually pass all the test so there is none to exclude.
81
- # ` (foo or not foo)` serves as a `true` value so it doesn't break when
82
- # $(EXTRA_SELECTORS) is non-empty
121
+ LIMNORIA_MARKERS := \
122
+ (foo or not foo) \
123
+ $( EXTRA_MARKERS )
83
124
LIMNORIA_SELECTORS := \
84
125
(foo or not foo) \
85
126
$(EXTRA_SELECTORS )
86
127
87
128
# Tests marked with arbitrary_client_tags or react_tag can't pass because Sable does not support client tags yet
88
- SABLE_SELECTORS := \
129
+ SABLE_MARKERS := \
89
130
(Sable or not implementation-specific) \
90
131
and not deprecated \
91
132
and not strict \
92
133
and not arbitrary_client_tags \
93
134
and not react_tag \
94
- and not list and not lusers and not time and not info \
135
+ $(EXTRA_MARKERS )
136
+ SABLE_SELECTORS := \
137
+ not list and not lusers and not time and not info \
95
138
$(EXTRA_SELECTORS )
96
139
97
- SOLANUM_SELECTORS := \
140
+ SOLANUM_MARKERS := \
98
141
not implementation-specific \
99
142
and not deprecated \
100
143
and not strict \
144
+ $(EXTRA_MARKERS )
145
+ SOLANUM_SELECTORS := \
146
+ (foo or not foo) \
101
147
$(EXTRA_SELECTORS )
102
148
103
- # Same as Limnoria
149
+ SOPEL_MARKERS := \
150
+ (foo or not foo) \
151
+ $(EXTRA_MARKERS )
104
152
SOPEL_SELECTORS := \
105
153
(foo or not foo) \
106
154
$(EXTRA_SELECTORS )
107
155
108
- # TheLounge can actually pass all the test so there is none to exclude.
109
- # ` (foo or not foo)` serves as a `true` value so it doesn't break when
110
- # $(EXTRA_SELECTORS) is non-empty
156
+ THELOUNGE_MARKERS := \
157
+ (foo or not foo) \
158
+ $( EXTRA_MARKERS )
111
159
THELOUNGE_SELECTORS := \
112
160
(foo or not foo) \
113
161
$(EXTRA_SELECTORS )
@@ -116,13 +164,16 @@ THELOUNGE_SELECTORS := \
116
164
# Tests marked with react_tag can't pass because Unreal blocks +draft/react https://github.com/unrealircd/unrealircd/pull/149
117
165
# Tests marked with private_chathistory can't pass because Unreal does not implement CHATHISTORY for DMs
118
166
119
- UNREALIRCD_SELECTORS := \
167
+ UNREALIRCD_MARKERS := \
120
168
not implementation-specific \
121
169
and not deprecated \
122
170
and not strict \
123
171
and not arbitrary_client_tags \
124
172
and not react_tag \
125
173
and not private_chathistory \
174
+ $(EXTRA_MARKERS )
175
+ UNREALIRCD_SELECTORS := \
176
+ (foo or not foo) \
126
177
$(EXTRA_SELECTORS )
127
178
128
179
.PHONY : all flakes bahamut charybdis ergo inspircd ircu2 snircd irc2 mammon nefarious limnoria sable sopel solanum unrealircd
@@ -138,150 +189,161 @@ bahamut:
138
189
-m ' not services' \
139
190
-n 4 \
140
191
-vv -s \
192
+ -m ' $(BAHAMUT_MARKERS)'
141
193
-k ' $(BAHAMUT_SELECTORS)'
142
194
143
195
bahamut-atheme :
144
196
$(PYTEST ) $(PYTEST_ARGS ) \
145
197
--controller=irctest.controllers.bahamut \
146
198
--services-controller=irctest.controllers.atheme_services \
147
- -m ' services' \
199
+ -m ' services and $(BAHAMUT_MARKERS) ' \
148
200
-k ' $(BAHAMUT_SELECTORS)'
149
201
150
202
bahamut-anope :
151
203
$(PYTEST ) $(PYTEST_ARGS ) \
152
204
--controller=irctest.controllers.bahamut \
153
205
--services-controller=irctest.controllers.anope_services \
154
- -m ' services' \
206
+ -m ' services and $(BAHAMUT_MARKERS) ' \
155
207
-k ' $(BAHAMUT_SELECTORS)'
156
208
157
209
charybdis :
158
210
$(PYTEST ) $(PYTEST_ARGS ) \
159
211
--controller=irctest.controllers.charybdis \
160
212
--services-controller=irctest.controllers.atheme_services \
213
+ -m ' $(CHARYBDIS_MARKERS)'
161
214
-k ' $(CHARYBDIS_SELECTORS)'
162
215
163
216
ergo :
164
217
$(PYTEST ) $(PYTEST_ARGS ) \
165
218
--controller irctest.controllers.ergo \
219
+ -m ' $(ERGO_MARKERS)'
166
220
-k " $( ERGO_SELECTORS) "
167
221
168
222
hybrid :
169
223
$(PYTEST ) $(PYTEST_ARGS ) \
170
224
--controller irctest.controllers.hybrid \
171
225
--services-controller=irctest.controllers.anope_services \
226
+ -m ' $(HYBRID_MARKERS)'
172
227
-k " $( HYBRID_SELECTORS) "
173
228
174
229
inspircd :
175
230
$(PYTEST ) $(PYTEST_ARGS ) \
176
231
--controller=irctest.controllers.inspircd \
177
- -m ' not services' \
232
+ -m ' not services and $(INSPIRCD_MARKERS) ' \
178
233
-k ' $(INSPIRCD_SELECTORS)'
179
234
180
235
inspircd-atheme :
181
236
$(PYTEST ) $(PYTEST_ARGS ) \
182
237
--controller=irctest.controllers.inspircd \
183
238
--services-controller=irctest.controllers.atheme_services \
184
- -m ' services' \
239
+ -m ' services and $(INSPIRCD_MARKERS) ' \
185
240
-k ' $(INSPIRCD_SELECTORS)'
186
241
187
242
inspircd-anope :
188
243
$(PYTEST ) $(PYTEST_ARGS ) \
189
244
--controller=irctest.controllers.inspircd \
190
245
--services-controller=irctest.controllers.anope_services \
191
- -m ' services' \
246
+ -m ' services and $(INSPIRCD_MARKERS) ' \
192
247
-k ' $(INSPIRCD_SELECTORS)'
193
248
194
249
ircu2 :
195
250
$(PYTEST ) $(PYTEST_ARGS ) \
196
251
--controller=irctest.controllers.ircu2 \
197
- -m ' not services and not IRCv3 ' \
252
+ -m ' not services and $(IRCU2_MARKERS) ' \
198
253
-n 4 \
199
254
-k ' $(IRCU2_SELECTORS)'
200
255
201
256
nefarious :
202
257
$(PYTEST ) $(PYTEST_ARGS ) \
203
258
--controller=irctest.controllers.nefarious \
204
- -m ' not services' \
259
+ -m ' not services and $(NEFARIOUS_MARKERS) ' \
205
260
-n 4 \
206
261
-k ' $(NEFARIOUS_SELECTORS)'
207
262
208
263
snircd :
209
264
$(PYTEST ) $(PYTEST_ARGS ) \
210
265
--controller=irctest.controllers.snircd \
211
- -m ' not services and not IRCv3 ' \
266
+ -m ' not services and $(SNIRCD_MARKERS) ' \
212
267
-n 4 \
213
268
-k ' $(SNIRCD_SELECTORS)'
214
269
215
270
irc2 :
216
271
$(PYTEST ) $(PYTEST_ARGS ) \
217
272
--controller=irctest.controllers.irc2 \
218
- -m ' not services and not IRCv3 ' \
273
+ -m ' not services and $(IRCU2_MARKERS) ' \
219
274
-n 4 \
220
275
-k ' $(IRC2_SELECTORS)'
221
276
222
277
limnoria :
223
278
$(PYTEST ) $(PYTEST_ARGS ) \
224
279
--controller=irctest.controllers.limnoria \
280
+ -m ' $(LIMNORIA_MARKERS)' \
225
281
-k ' $(LIMNORIA_SELECTORS)'
226
282
227
283
mammon :
228
284
$(PYTEST ) $(PYTEST_ARGS ) \
229
285
--controller=irctest.controllers.mammon \
286
+ -m ' $(MAMMON_MARKERS)' \
230
287
-k ' $(MAMMON_SELECTORS)'
231
288
232
289
plexus4 :
233
290
$(PYTEST ) $(PYTEST_ARGS ) \
234
291
--controller irctest.controllers.plexus4 \
235
292
--services-controller=irctest.controllers.anope_services \
293
+ -m ' $(PLEXUS4_MARKERS)' \
236
294
-k " $( PLEXUS4_SELECTORS) "
237
295
238
296
ngircd :
239
297
$(PYTEST ) $(PYTEST_ARGS ) \
240
298
--controller irctest.controllers.ngircd \
241
- -m ' not services' \
299
+ -m ' services and $(NGIRCD_MARKERS) ' \
242
300
-n 4 \
243
301
-k " $( NGIRCD_SELECTORS) "
244
302
245
303
ngircd-anope :
246
304
$(PYTEST ) $(PYTEST_ARGS ) \
247
305
--controller irctest.controllers.ngircd \
248
306
--services-controller=irctest.controllers.anope_services \
249
- -m ' services' \
307
+ -m ' services and $(NGIRCD_MARKERS) ' \
250
308
-k " $( NGIRCD_SELECTORS) "
251
309
252
310
ngircd-atheme :
253
311
$(PYTEST ) $(PYTEST_ARGS ) \
254
312
--controller irctest.controllers.ngircd \
255
313
--services-controller=irctest.controllers.atheme_services \
256
- -m ' services' \
314
+ -m ' services and $(NGIRCD_MARKERS) ' \
257
315
-k " $( NGIRCD_SELECTORS) "
258
316
259
317
sable :
260
318
$(PYTEST ) $(PYTEST_ARGS ) \
261
319
--controller=irctest.controllers.sable \
320
+ -m ' $(SABLE_MARKERS)' \
262
321
-n 20 \
263
322
-k ' $(SABLE_SELECTORS)'
264
323
265
324
solanum :
266
325
$(PYTEST ) $(PYTEST_ARGS ) \
267
326
--controller=irctest.controllers.solanum \
268
327
--services-controller=irctest.controllers.atheme_services \
328
+ -m ' $(SOPEL_MARKERS)' \
269
329
-k ' $(SOLANUM_SELECTORS)'
270
330
271
331
sopel :
272
332
$(PYTEST ) $(PYTEST_ARGS ) \
273
333
--controller=irctest.controllers.sopel \
334
+ -m ' $(SOPEL_MARKERS)' \
274
335
-k ' $(SOPEL_SELECTORS)'
275
336
276
337
thelounge :
277
338
$(PYTEST ) $(PYTEST_ARGS ) \
278
339
--controller=irctest.controllers.thelounge \
340
+ -m ' $(THELOUNGE_MARKERS)' \
279
341
-k ' $(THELOUNGE_SELECTORS)'
280
342
281
343
unrealircd :
282
344
$(PYTEST ) $(PYTEST_ARGS ) \
283
345
--controller=irctest.controllers.unrealircd \
284
- -m ' not services' \
346
+ -m ' not services and $(UNREALIRCD_MARKERS) ' \
285
347
-k ' $(UNREALIRCD_SELECTORS)'
286
348
287
349
unrealircd-5 : unrealircd
@@ -290,19 +352,19 @@ unrealircd-atheme:
290
352
$(PYTEST ) $(PYTEST_ARGS ) \
291
353
--controller=irctest.controllers.unrealircd \
292
354
--services-controller=irctest.controllers.atheme_services \
293
- -m ' services' \
355
+ -m ' services and $(UNREALIRCD_MARKERS) ' \
294
356
-k ' $(UNREALIRCD_SELECTORS)'
295
357
296
358
unrealircd-anope :
297
359
$(PYTEST ) $(PYTEST_ARGS ) \
298
360
--controller=irctest.controllers.unrealircd \
299
361
--services-controller=irctest.controllers.anope_services \
300
- -m ' services' \
362
+ -m ' services and $(UNREALIRCD_MARKERS) ' \
301
363
-k ' $(UNREALIRCD_SELECTORS)'
302
364
303
365
unrealircd-dlk :
304
366
pifpaf run mysql -- $(PYTEST ) $(PYTEST_ARGS ) \
305
367
--controller=irctest.controllers.unrealircd \
306
368
--services-controller=irctest.controllers.dlk_services \
307
- -m ' services' \
369
+ -m ' services and $(UNREALIRCD_MARKERS) ' \
308
370
-k ' $(UNREALIRCD_SELECTORS)'
0 commit comments