@@ -4,110 +4,158 @@ PYTEST ?= python3 -m pytest
44# pytest-xdist is installed)
55PYTEST_ARGS ?=
66
7+ # Will be appended at the end of the -m argument to pytest
8+ EXTRA_MARKERS ?=
9+
710# Will be appended at the end of the -k argument to pytest
811EXTRA_SELECTORS ?=
912
10- BAHAMUT_SELECTORS := \
13+ BAHAMUT_MARKERS := \
1114 not implementation-specific \
1215 and not deprecated \
1316 and not strict \
14- and not IRCv3 \
17+ and not IRCv3
18+ BAHAMUT_SELECTORS := \
19+ (foo or not foo) \
1520 $(EXTRA_SELECTORS )
1621
17- CHARYBDIS_SELECTORS := \
22+ CHARYBDIS_MARKERS := \
1823 not implementation-specific \
1924 and not deprecated \
2025 and not strict \
26+ $(EXTRA_MARKERS )
27+ CHARYBDIS_SELECTORS := \
28+ (foo or not foo) \
2129 $(EXTRA_SELECTORS )
2230
23- ERGO_SELECTORS := \
31+ ERGO_MARKERS := \
2432 (Ergo or not implementation-specific) \
2533 and not deprecated \
34+ $(EXTRA_MARKERS )
35+ ERGO_SELECTORS := \
36+ (foo or not foo) \
2637 $(EXTRA_SELECTORS )
2738
28- HYBRID_SELECTORS := \
39+ HYBRID_MARKERS := \
2940 not implementation-specific \
3041 and not deprecated \
42+ $(EXTRA_MARKERS )
43+ HYBRID_SELECTORS := \
44+ (foo or not foo) \
3145 $(EXTRA_SELECTORS )
3246
33- INSPIRCD_SELECTORS := \
47+ INSPIRCD_MARKERS := \
3448 not implementation-specific \
3549 and not deprecated \
3650 and not strict \
51+ $(EXTRA_MARKERS )
52+ INSPIRCD_SELECTORS := \
53+ (foo or not foo) \
3754 $(EXTRA_SELECTORS )
3855
39- IRCU2_SELECTORS := \
56+ IRCU2_MARKERS := \
4057 not implementation-specific \
4158 and not deprecated \
4259 and not strict \
60+ and not IRCv3 \
61+ $(EXTRA_MARKERS )
62+ IRCU2_SELECTORS := \
63+ (foo or not foo) \
4364 $(EXTRA_SELECTORS )
4465
45- NEFARIOUS_SELECTORS := \
66+ NEFARIOUS_MARKERS := \
4667 not implementation-specific \
4768 and not deprecated \
4869 and not strict \
70+ $(EXTRA_MARKERS )
71+ NEFARIOUS_SELECTORS := \
72+ (foo or not foo) \
4973 $(EXTRA_SELECTORS )
5074
51- SNIRCD_SELECTORS := \
75+ SNIRCD_MARKERS := \
5276 not implementation-specific \
5377 and not deprecated \
5478 and not strict \
79+ and not IRCv3 \
80+ $(EXTRA_MARKERS )
81+ SNIRCD_SELECTORS := \
82+ (foo or not foo) \
5583 $(EXTRA_SELECTORS )
5684
57- IRC2_SELECTORS := \
85+ IRC2_MARKERS := \
5886 not implementation-specific \
5987 and not deprecated \
6088 and not strict \
89+ and not IRCv3 \
90+ $(EXTRA_MARKERS )
91+ IRC2_SELECTORS := \
92+ (foo or not foo) \
6193 $(EXTRA_SELECTORS )
6294
63- MAMMON_SELECTORS := \
95+ MAMMON_MARKERS := \
6496 not implementation-specific \
6597 and not deprecated \
6698 and not strict \
99+ $(EXTRA_MARKERS )
100+ MAMMON_SELECTORS := \
101+ (foo or not foo) \
67102 $(EXTRA_SELECTORS )
68103
69- NGIRCD_SELECTORS := \
104+ NGIRCD_MARKERS := \
70105 not implementation-specific \
71106 and not deprecated \
72107 and not strict \
108+ $(EXTRA_MARKERS )
109+ NGIRCD_SELECTORS := \
110+ (foo or not foo) \
73111 $(EXTRA_SELECTORS )
74112
75- PLEXUS4_SELECTORS := \
113+ PLEXUS4_MARKERS := \
76114 not implementation-specific \
77115 and not deprecated \
116+ $(EXTRA_MARKERS )
117+ PLEXUS4_SELECTORS := \
118+ (foo or not foo) \
78119 $(EXTRA_SELECTORS )
79120
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 )
83124LIMNORIA_SELECTORS := \
84125 (foo or not foo) \
85126 $(EXTRA_SELECTORS )
86127
87128# 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 := \
89130 (Sable or not implementation-specific) \
90131 and not deprecated \
91132 and not strict \
92133 and not arbitrary_client_tags \
93134 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 \
95138 $(EXTRA_SELECTORS )
96139
97- SOLANUM_SELECTORS := \
140+ SOLANUM_MARKERS := \
98141 not implementation-specific \
99142 and not deprecated \
100143 and not strict \
144+ $(EXTRA_MARKERS )
145+ SOLANUM_SELECTORS := \
146+ (foo or not foo) \
101147 $(EXTRA_SELECTORS )
102148
103- # Same as Limnoria
149+ SOPEL_MARKERS := \
150+ (foo or not foo) \
151+ $(EXTRA_MARKERS )
104152SOPEL_SELECTORS := \
105153 (foo or not foo) \
106154 $(EXTRA_SELECTORS )
107155
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 )
111159THELOUNGE_SELECTORS := \
112160 (foo or not foo) \
113161 $(EXTRA_SELECTORS )
@@ -116,13 +164,16 @@ THELOUNGE_SELECTORS := \
116164# Tests marked with react_tag can't pass because Unreal blocks +draft/react https://github.com/unrealircd/unrealircd/pull/149
117165# Tests marked with private_chathistory can't pass because Unreal does not implement CHATHISTORY for DMs
118166
119- UNREALIRCD_SELECTORS := \
167+ UNREALIRCD_MARKERS := \
120168 not implementation-specific \
121169 and not deprecated \
122170 and not strict \
123171 and not arbitrary_client_tags \
124172 and not react_tag \
125173 and not private_chathistory \
174+ $(EXTRA_MARKERS )
175+ UNREALIRCD_SELECTORS := \
176+ (foo or not foo) \
126177 $(EXTRA_SELECTORS )
127178
128179.PHONY : all flakes bahamut charybdis ergo inspircd ircu2 snircd irc2 mammon nefarious limnoria sable sopel solanum unrealircd
@@ -138,150 +189,161 @@ bahamut:
138189 -m ' not services' \
139190 -n 4 \
140191 -vv -s \
192+ -m ' $(BAHAMUT_MARKERS)'
141193 -k ' $(BAHAMUT_SELECTORS)'
142194
143195bahamut-atheme :
144196 $(PYTEST ) $(PYTEST_ARGS ) \
145197 --controller=irctest.controllers.bahamut \
146198 --services-controller=irctest.controllers.atheme_services \
147- -m ' services' \
199+ -m ' services and $(BAHAMUT_MARKERS) ' \
148200 -k ' $(BAHAMUT_SELECTORS)'
149201
150202bahamut-anope :
151203 $(PYTEST ) $(PYTEST_ARGS ) \
152204 --controller=irctest.controllers.bahamut \
153205 --services-controller=irctest.controllers.anope_services \
154- -m ' services' \
206+ -m ' services and $(BAHAMUT_MARKERS) ' \
155207 -k ' $(BAHAMUT_SELECTORS)'
156208
157209charybdis :
158210 $(PYTEST ) $(PYTEST_ARGS ) \
159211 --controller=irctest.controllers.charybdis \
160212 --services-controller=irctest.controllers.atheme_services \
213+ -m ' $(CHARYBDIS_MARKERS)'
161214 -k ' $(CHARYBDIS_SELECTORS)'
162215
163216ergo :
164217 $(PYTEST ) $(PYTEST_ARGS ) \
165218 --controller irctest.controllers.ergo \
219+ -m ' $(ERGO_MARKERS)'
166220 -k " $( ERGO_SELECTORS) "
167221
168222hybrid :
169223 $(PYTEST ) $(PYTEST_ARGS ) \
170224 --controller irctest.controllers.hybrid \
171225 --services-controller=irctest.controllers.anope_services \
226+ -m ' $(HYBRID_MARKERS)'
172227 -k " $( HYBRID_SELECTORS) "
173228
174229inspircd :
175230 $(PYTEST ) $(PYTEST_ARGS ) \
176231 --controller=irctest.controllers.inspircd \
177- -m ' not services' \
232+ -m ' not services and $(INSPIRCD_MARKERS) ' \
178233 -k ' $(INSPIRCD_SELECTORS)'
179234
180235inspircd-atheme :
181236 $(PYTEST ) $(PYTEST_ARGS ) \
182237 --controller=irctest.controllers.inspircd \
183238 --services-controller=irctest.controllers.atheme_services \
184- -m ' services' \
239+ -m ' services and $(INSPIRCD_MARKERS) ' \
185240 -k ' $(INSPIRCD_SELECTORS)'
186241
187242inspircd-anope :
188243 $(PYTEST ) $(PYTEST_ARGS ) \
189244 --controller=irctest.controllers.inspircd \
190245 --services-controller=irctest.controllers.anope_services \
191- -m ' services' \
246+ -m ' services and $(INSPIRCD_MARKERS) ' \
192247 -k ' $(INSPIRCD_SELECTORS)'
193248
194249ircu2 :
195250 $(PYTEST ) $(PYTEST_ARGS ) \
196251 --controller=irctest.controllers.ircu2 \
197- -m ' not services and not IRCv3 ' \
252+ -m ' not services and $(IRCU2_MARKERS) ' \
198253 -n 4 \
199254 -k ' $(IRCU2_SELECTORS)'
200255
201256nefarious :
202257 $(PYTEST ) $(PYTEST_ARGS ) \
203258 --controller=irctest.controllers.nefarious \
204- -m ' not services' \
259+ -m ' not services and $(NEFARIOUS_MARKERS) ' \
205260 -n 4 \
206261 -k ' $(NEFARIOUS_SELECTORS)'
207262
208263snircd :
209264 $(PYTEST ) $(PYTEST_ARGS ) \
210265 --controller=irctest.controllers.snircd \
211- -m ' not services and not IRCv3 ' \
266+ -m ' not services and $(SNIRCD_MARKERS) ' \
212267 -n 4 \
213268 -k ' $(SNIRCD_SELECTORS)'
214269
215270irc2 :
216271 $(PYTEST ) $(PYTEST_ARGS ) \
217272 --controller=irctest.controllers.irc2 \
218- -m ' not services and not IRCv3 ' \
273+ -m ' not services and $(IRCU2_MARKERS) ' \
219274 -n 4 \
220275 -k ' $(IRC2_SELECTORS)'
221276
222277limnoria :
223278 $(PYTEST ) $(PYTEST_ARGS ) \
224279 --controller=irctest.controllers.limnoria \
280+ -m ' $(LIMNORIA_MARKERS)' \
225281 -k ' $(LIMNORIA_SELECTORS)'
226282
227283mammon :
228284 $(PYTEST ) $(PYTEST_ARGS ) \
229285 --controller=irctest.controllers.mammon \
286+ -m ' $(MAMMON_MARKERS)' \
230287 -k ' $(MAMMON_SELECTORS)'
231288
232289plexus4 :
233290 $(PYTEST ) $(PYTEST_ARGS ) \
234291 --controller irctest.controllers.plexus4 \
235292 --services-controller=irctest.controllers.anope_services \
293+ -m ' $(PLEXUS4_MARKERS)' \
236294 -k " $( PLEXUS4_SELECTORS) "
237295
238296ngircd :
239297 $(PYTEST ) $(PYTEST_ARGS ) \
240298 --controller irctest.controllers.ngircd \
241- -m ' not services' \
299+ -m ' services and $(NGIRCD_MARKERS) ' \
242300 -n 4 \
243301 -k " $( NGIRCD_SELECTORS) "
244302
245303ngircd-anope :
246304 $(PYTEST ) $(PYTEST_ARGS ) \
247305 --controller irctest.controllers.ngircd \
248306 --services-controller=irctest.controllers.anope_services \
249- -m ' services' \
307+ -m ' services and $(NGIRCD_MARKERS) ' \
250308 -k " $( NGIRCD_SELECTORS) "
251309
252310ngircd-atheme :
253311 $(PYTEST ) $(PYTEST_ARGS ) \
254312 --controller irctest.controllers.ngircd \
255313 --services-controller=irctest.controllers.atheme_services \
256- -m ' services' \
314+ -m ' services and $(NGIRCD_MARKERS) ' \
257315 -k " $( NGIRCD_SELECTORS) "
258316
259317sable :
260318 $(PYTEST ) $(PYTEST_ARGS ) \
261319 --controller=irctest.controllers.sable \
320+ -m ' $(SABLE_MARKERS)' \
262321 -n 20 \
263322 -k ' $(SABLE_SELECTORS)'
264323
265324solanum :
266325 $(PYTEST ) $(PYTEST_ARGS ) \
267326 --controller=irctest.controllers.solanum \
268327 --services-controller=irctest.controllers.atheme_services \
328+ -m ' $(SOPEL_MARKERS)' \
269329 -k ' $(SOLANUM_SELECTORS)'
270330
271331sopel :
272332 $(PYTEST ) $(PYTEST_ARGS ) \
273333 --controller=irctest.controllers.sopel \
334+ -m ' $(SOPEL_MARKERS)' \
274335 -k ' $(SOPEL_SELECTORS)'
275336
276337thelounge :
277338 $(PYTEST ) $(PYTEST_ARGS ) \
278339 --controller=irctest.controllers.thelounge \
340+ -m ' $(THELOUNGE_MARKERS)' \
279341 -k ' $(THELOUNGE_SELECTORS)'
280342
281343unrealircd :
282344 $(PYTEST ) $(PYTEST_ARGS ) \
283345 --controller=irctest.controllers.unrealircd \
284- -m ' not services' \
346+ -m ' not services and $(UNREALIRCD_MARKERS) ' \
285347 -k ' $(UNREALIRCD_SELECTORS)'
286348
287349unrealircd-5 : unrealircd
@@ -290,19 +352,19 @@ unrealircd-atheme:
290352 $(PYTEST ) $(PYTEST_ARGS ) \
291353 --controller=irctest.controllers.unrealircd \
292354 --services-controller=irctest.controllers.atheme_services \
293- -m ' services' \
355+ -m ' services and $(UNREALIRCD_MARKERS) ' \
294356 -k ' $(UNREALIRCD_SELECTORS)'
295357
296358unrealircd-anope :
297359 $(PYTEST ) $(PYTEST_ARGS ) \
298360 --controller=irctest.controllers.unrealircd \
299361 --services-controller=irctest.controllers.anope_services \
300- -m ' services' \
362+ -m ' services and $(UNREALIRCD_MARKERS) ' \
301363 -k ' $(UNREALIRCD_SELECTORS)'
302364
303365unrealircd-dlk :
304366 pifpaf run mysql -- $(PYTEST ) $(PYTEST_ARGS ) \
305367 --controller=irctest.controllers.unrealircd \
306368 --services-controller=irctest.controllers.dlk_services \
307- -m ' services' \
369+ -m ' services and $(UNREALIRCD_MARKERS) ' \
308370 -k ' $(UNREALIRCD_SELECTORS)'
0 commit comments