Skip to content

Commit 778510e

Browse files
committed
Bump Unreal to 6.0.3 and remove ELIST workarounds (#158)
Workarounds that are only still needed for Unreal 5 and and Hybrid/Plexus
1 parent 8e2670d commit 778510e

File tree

4 files changed

+46
-78
lines changed

4 files changed

+46
-78
lines changed

.github/workflows/test-stable.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,7 @@ jobs:
342342
uses: actions/checkout@v2
343343
with:
344344
path: unrealircd
345-
ref: daa0c11f285c7123ba9fa2966dee2d1a17729f1e
345+
ref: cedd23ae9cdd5985ce16e9869cbdb808479c3fc4
346346
repository: unrealircd/unrealircd
347347
- name: Build UnrealIRCd 6
348348
run: |

irctest/controllers/unrealircd.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,7 @@ class UnrealircdController(BaseServerController, DirectoryBasedController):
139139
supports_sts = False
140140

141141
extban_mute_char = "quiet" if installed_version() >= 6 else "q"
142+
software_version = installed_version()
142143

143144
def create_config(self) -> None:
144145
super().create_config()

irctest/server_tests/list.py

Lines changed: 42 additions & 75 deletions
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,17 @@ def _sleep_minutes(self, n):
236236

237237
@cases.mark_isupport("ELIST")
238238
@cases.mark_specifications("Modern")
239+
@cases.xfailIfSoftware(
240+
["Plexus4", "Hybrid"],
241+
"Hybrid and Plexus4 filter on ELIST=C with the opposite meaning",
242+
)
243+
@cases.xfailIf(
244+
lambda self: bool(
245+
self.controller.software_name == "UnrealIRCd"
246+
and self.controller.software_version == 5
247+
),
248+
"UnrealIRCd <6.0.3 filters on ELIST=C with the opposite meaning",
249+
)
239250
def testListCreationTime(self):
240251
"""
241252
" C: Searching based on channel creation time, via the "C<val" and "C>val"
@@ -282,51 +293,32 @@ def testListCreationTime(self):
282293

283294
self._sleep_minutes(1)
284295

285-
if self.controller.software_name in ("UnrealIRCd", "Plexus4", "Hybrid"):
286-
self.sendLine(2, "LIST C<2")
287-
self.assertEqual(self._parseChanList(2), {"#chan1"})
288-
289-
self.sendLine(2, "LIST C>2")
290-
self.assertEqual(self._parseChanList(2), {"#chan2"})
291-
292-
self.sendLine(2, "LIST C>0")
293-
self.assertEqual(self._parseChanList(2), set())
296+
self.sendLine(2, "LIST C>2")
297+
self.assertEqual(self._parseChanList(2), {"#chan1"})
294298

295-
self.sendLine(2, "LIST C<0")
296-
self.assertEqual(self._parseChanList(2), {"#chan1", "#chan2"})
299+
self.sendLine(2, "LIST C<2")
300+
self.assertEqual(self._parseChanList(2), {"#chan2"})
297301

298-
self.sendLine(2, "LIST C>10")
302+
self.sendLine(2, "LIST C<0")
303+
if self.controller.software_name == "InspIRCd":
299304
self.assertEqual(self._parseChanList(2), {"#chan1", "#chan2"})
300-
elif self.controller.software_name in (
301-
"Solanum",
302-
"Charybdis",
303-
"InspIRCd",
304-
"Nefarious",
305-
):
306-
self.sendLine(2, "LIST C>2")
307-
self.assertEqual(self._parseChanList(2), {"#chan1"})
308-
309-
self.sendLine(2, "LIST C<2")
310-
self.assertEqual(self._parseChanList(2), {"#chan2"})
311-
312-
self.sendLine(2, "LIST C<0")
313-
if self.controller.software_name == "InspIRCd":
314-
self.assertEqual(self._parseChanList(2), {"#chan1", "#chan2"})
315-
else:
316-
self.assertEqual(self._parseChanList(2), set())
305+
else:
306+
self.assertEqual(self._parseChanList(2), set())
317307

318-
self.sendLine(2, "LIST C>0")
319-
self.assertEqual(self._parseChanList(2), {"#chan1", "#chan2"})
308+
self.sendLine(2, "LIST C>0")
309+
self.assertEqual(self._parseChanList(2), {"#chan1", "#chan2"})
320310

321-
self.sendLine(2, "LIST C<10")
322-
self.assertEqual(self._parseChanList(2), {"#chan1", "#chan2"})
323-
else:
324-
assert False, f"{self.controller.software_name} not supported"
311+
self.sendLine(2, "LIST C<10")
312+
self.assertEqual(self._parseChanList(2), {"#chan1", "#chan2"})
325313

326314
@cases.mark_isupport("ELIST")
327315
@cases.mark_specifications("Modern")
328-
@cases.xfailIfSoftware(
329-
["UnrealIRCd"], "UnrealIRCd advertises ELIST=T but does not implement it"
316+
@cases.xfailIf(
317+
lambda self: bool(
318+
self.controller.software_name == "UnrealIRCd"
319+
and self.controller.software_version == 5
320+
),
321+
"UnrealIRCd <6.0.3 advertises ELIST=T but does not implement it",
330322
)
331323
def testListTopicTime(self):
332324
"""
@@ -371,46 +363,21 @@ def testListTopicTime(self):
371363

372364
self._sleep_minutes(1)
373365

374-
if self.controller.software_name in ("UnrealIRCd",):
375-
self.sendLine(1, "LIST T<2")
376-
self.assertEqual(self._parseChanList(1), {"#chan1"})
377-
378-
self.sendLine(1, "LIST T>2")
379-
self.assertEqual(self._parseChanList(1), {"#chan2"})
380-
381-
self.sendLine(1, "LIST T>0")
382-
self.assertEqual(self._parseChanList(1), set())
366+
self.sendLine(1, "LIST T>2")
367+
self.assertEqual(self._parseChanList(1), {"#chan1"})
383368

384-
self.sendLine(1, "LIST T<0")
385-
self.assertEqual(self._parseChanList(1), {"#chan1", "#chan2"})
369+
self.sendLine(1, "LIST T<2")
370+
self.assertEqual(self._parseChanList(1), {"#chan2"})
386371

387-
self.sendLine(1, "LIST T>10")
372+
self.sendLine(1, "LIST T<0")
373+
if self.controller.software_name == "InspIRCd":
374+
# Insp internally represents "LIST T>0" like "LIST"
388375
self.assertEqual(self._parseChanList(1), {"#chan1", "#chan2"})
389-
elif self.controller.software_name in (
390-
"Solanum",
391-
"Charybdis",
392-
"InspIRCd",
393-
"Plexus4",
394-
"Hybrid",
395-
"Nefarious",
396-
):
397-
self.sendLine(1, "LIST T>2")
398-
self.assertEqual(self._parseChanList(1), {"#chan1"})
399-
400-
self.sendLine(1, "LIST T<2")
401-
self.assertEqual(self._parseChanList(1), {"#chan2"})
402-
403-
self.sendLine(1, "LIST T<0")
404-
if self.controller.software_name == "InspIRCd":
405-
# Insp internally represents "LIST T>0" like "LIST"
406-
self.assertEqual(self._parseChanList(1), {"#chan1", "#chan2"})
407-
else:
408-
self.assertEqual(self._parseChanList(1), set())
376+
else:
377+
self.assertEqual(self._parseChanList(1), set())
409378

410-
self.sendLine(1, "LIST T>0")
411-
self.assertEqual(self._parseChanList(1), {"#chan1", "#chan2"})
379+
self.sendLine(1, "LIST T>0")
380+
self.assertEqual(self._parseChanList(1), {"#chan1", "#chan2"})
412381

413-
self.sendLine(1, "LIST T<10")
414-
self.assertEqual(self._parseChanList(1), {"#chan1", "#chan2"})
415-
else:
416-
assert False, f"{self.controller.software_name} not supported"
382+
self.sendLine(1, "LIST T<10")
383+
self.assertEqual(self._parseChanList(1), {"#chan1", "#chan2"})

workflows.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -267,8 +267,8 @@ software:
267267
name: UnrealIRCd 6
268268
repository: unrealircd/unrealircd
269269
refs:
270-
stable: daa0c11f285c7123ba9fa2966dee2d1a17729f1e # 6.0.2 + a few commits
271-
release: 29fd2e772a6b4b9107daa4e3c237df454b055810 # 6.0.2
270+
stable: cedd23ae9cdd5985ce16e9869cbdb808479c3fc4 # 6.0.3
271+
release: cedd23ae9cdd5985ce16e9869cbdb808479c3fc4 # 6.0.3
272272
devel: unreal60_dev
273273
devel_release: null
274274
path: unrealircd

0 commit comments

Comments
 (0)