James Lu
19f7ba38b3
Begin integrating ircdocs/parser-tests
2019-09-10 18:11:07 -07:00
James Lu
f9368dd5cc
Protocol tests for get_hostmask(), get_friendly_name()
2019-08-26 16:54:27 -07:00
James Lu
2baec4c65a
Protocol tests for wrap_modes()
2019-08-26 16:47:49 -07:00
James Lu
ee4997dd72
Tests for join_modes, base case tests for apply_modes / reverse_modes
2019-08-26 16:24:58 -07:00
James Lu
ebce431ba4
reverse_modes: test cycling prefix modes
2019-08-26 16:10:08 -07:00
James Lu
a1f3af9099
reverse_modes: deduplicate reversing modes with arguments
2019-08-26 16:10:08 -07:00
James Lu
d93c071446
reverse_modes: test mode cycling with simple modes and bans
2019-08-26 16:10:08 -07:00
James Lu
9168880204
parse_modes: fix handling of +b-b ban cycles
2019-08-26 16:10:08 -07:00
James Lu
b685f416f6
reverse_modes: treat mode arguments case insensitively
2019-08-26 16:10:08 -07:00
James Lu
0533827ddf
reverse_modes: add basic tests
2019-08-26 16:10:02 -07:00
James Lu
808e1d1f5a
protocol tests: cleanup
2019-08-26 12:59:57 -07:00
James Lu
304631ebd0
Fixes to clientbot._get_UID() behaviour
2019-08-26 12:17:07 -07:00
James Lu
27eed3334b
parse_modes: test combinations of nicks and UIDs in prefix modes
2019-08-23 21:24:00 -07:00
James Lu
da58669de5
parse_modes: case fold parameters to modes
2019-08-23 21:01:55 -07:00
James Lu
6ad34672d3
apply_modes: fix statekeeping with current modes mapping
2019-08-23 00:22:25 -07:00
James Lu
cb4d2cc384
Add more mode cycling (+b/-b, etc.) tests
2019-08-23 00:11:21 -07:00
James Lu
3eb90fa65c
More rigorous testing of +k/-k parsing
2019-08-23 00:11:21 -07:00
James Lu
fe51f71a6e
apply_modes: refactor checks for existing modes
2019-08-23 00:10:30 -07:00
James Lu
a885b79306
More tests for parse_modes(), apply_modes()
2019-08-22 22:58:24 -07:00
James Lu
5d579481aa
Base protocol tests for _get_UID, parse_modes
2019-08-18 20:55:10 -07:00
James Lu
4a8c96c883
And now, a test fixture for protocols/
2019-08-18 16:36:02 -07:00
James Lu
80188c3673
Sort imports via isort
2019-07-14 15:12:29 -07:00
James Lu
b7d93fe86a
utils: add match_text(), general glob matching function
...
In preparation for ircmatch removal (#636 )
2019-06-21 12:51:12 -07:00
James Lu
c8b8762c12
utils: add parse_duration(), which takes in a duration string and returns the equiv. amt of seconds ( #504 )
2018-06-15 19:40:05 -07:00
James Lu
e38cd0ada2
get_hostname_type: return 0 for hostnames instead of False for consistency
2018-06-15 14:02:30 -07:00
James Lu
5ea33baa8e
utils: add get_hostname_type() to autodetect address types ( #212 )
2018-06-15 02:39:20 -07:00
James Lu
c919c523dc
utils: add remove_range()
...
"""
Removes a range string of (one-indexed) items from the list.
Range strings are indices or ranges of them joined together with a ",":
e.g. "5", "2", "2-10", "1,3,5-8"
See test/test_utils.py for more complete examples.
"""
2018-06-09 17:03:40 -07:00
James Lu
de62b2e77a
utils: add strip_irc_formatting()
2018-06-09 16:22:14 -07:00