diff options
author | Frantisek Sumsal <frantisek@sumsal.cz> | 2020-06-06 12:50:48 +0200 |
---|---|---|
committer | Frantisek Sumsal <frantisek@sumsal.cz> | 2020-06-06 18:33:35 +0200 |
commit | 7887e58051f0c4ae712dd6c2af461369d53e37b7 (patch) | |
tree | efa21b6e93ff2b3455622f1512dd128b314982d8 /test | |
parent | 6495ceddf38aed2c9efdcf9d3440140190800b55 (diff) | |
download | systemd-7887e58051f0c4ae712dd6c2af461369d53e37b7.tar.gz |
test: avoid failing due to unexpected precision
After today's Arch Linux image update, there seems to be a slight change
in delay reporting which breaks some asserts in
systemd-networkd-tests.py:
Expected:
limit 100 delay 50.0ms 10.0ms loss 20%
Current:
limit 100 delay 50ms 10ms loss 20%
Diffstat (limited to 'test')
-rwxr-xr-x | test/test-network/systemd-networkd-tests.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/test/test-network/systemd-networkd-tests.py b/test/test-network/systemd-networkd-tests.py index da4063d51c..43730d9f85 100755 --- a/test/test-network/systemd-networkd-tests.py +++ b/test/test-network/systemd-networkd-tests.py @@ -2354,7 +2354,7 @@ class NetworkdNetworkTests(unittest.TestCase, Utilities): output = check_output('tc qdisc show dev test1') print(output) self.assertRegex(output, 'qdisc netem') - self.assertRegex(output, 'limit 100 delay 50.0ms 10.0ms loss 20%') + self.assertRegex(output, 'limit 100 delay 50(.0)?ms 10(.0)?ms loss 20%') self.assertRegex(output, 'qdisc ingress') output = check_output('tc qdisc show dev dummy98') @@ -2365,9 +2365,9 @@ class NetworkdNetworkTests(unittest.TestCase, Utilities): self.assertRegex(output, r'default (0x30|30)') self.assertRegex(output, 'qdisc netem 30: parent 2:30') - self.assertRegex(output, 'limit 100 delay 50.0ms 10.0ms loss 20%') + self.assertRegex(output, 'limit 100 delay 50(.0)?ms 10(.0)?ms loss 20%') self.assertRegex(output, 'qdisc fq_codel') - self.assertRegex(output, 'limit 20480p flows 2048 quantum 1400 target 10.0ms ce_threshold 100.0ms interval 200.0ms memory_limit 64Mb ecn') + self.assertRegex(output, 'limit 20480p flows 2048 quantum 1400 target 10(.0)?ms ce_threshold 100(.0)?ms interval 200(.0)?ms memory_limit 64Mb ecn') self.assertRegex(output, 'qdisc teql1 31: parent 2:31') @@ -2378,13 +2378,13 @@ class NetworkdNetworkTests(unittest.TestCase, Utilities): self.assertRegex(output, 'maxrate 1Mbit') self.assertRegex(output, 'qdisc codel 33: parent 2:33') - self.assertRegex(output, 'limit 2000p target 10.0ms ce_threshold 100.0ms interval 50.0ms ecn') + self.assertRegex(output, 'limit 2000p target 10(.0)?ms ce_threshold 100(.0)?ms interval 50(.0)?ms ecn') self.assertRegex(output, 'qdisc fq_codel 34: parent 2:34') - self.assertRegex(output, 'limit 20480p flows 2048 quantum 1400 target 10.0ms ce_threshold 100.0ms interval 200.0ms memory_limit 64Mb ecn') + self.assertRegex(output, 'limit 20480p flows 2048 quantum 1400 target 10(.0)?ms ce_threshold 100(.0)?ms interval 200(.0)?ms memory_limit 64Mb ecn') self.assertRegex(output, 'qdisc tbf 35: parent 2:35') - self.assertRegex(output, 'rate 1Gbit burst 5000b peakrate 100Gbit minburst 987500b lat 70.0ms') + self.assertRegex(output, 'rate 1Gbit burst 5000b peakrate 100Gbit minburst 987500b lat 70(.0)?ms') self.assertRegex(output, 'qdisc sfq 36: parent 2:36') self.assertRegex(output, 'perturb 5sec') |