diff options
author | Lennart Poettering <lennart@poettering.net> | 2020-06-24 19:07:41 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-24 19:07:41 +0200 |
commit | c4e90266dbc981ad6d601e860bb0df5e284dd8a9 (patch) | |
tree | eaad63101812f3dc38b2ef574cd67f255b80b090 /test | |
parent | Merge pull request #16106 from yuwata/network-tc-ets (diff) | |
parent | test-network: add tests for HTB settings (diff) | |
download | systemd-c4e90266dbc981ad6d601e860bb0df5e284dd8a9.tar.xz systemd-c4e90266dbc981ad6d601e860bb0df5e284dd8a9.zip |
Merge pull request #16093 from yuwata/network-htb-add-settings-15213
network: tc: add several settings for HTB
Diffstat (limited to 'test')
-rw-r--r-- | test/fuzz/fuzz-network-parser/directives.network | 6 | ||||
-rw-r--r-- | test/test-network/conf/25-qdisc-clsact-and-htb.network | 6 | ||||
-rwxr-xr-x | test/test-network/systemd-networkd-tests.py | 6 |
3 files changed, 16 insertions, 2 deletions
diff --git a/test/fuzz/fuzz-network-parser/directives.network b/test/fuzz/fuzz-network-parser/directives.network index ade153a378..562d244ba7 100644 --- a/test/fuzz/fuzz-network-parser/directives.network +++ b/test/fuzz/fuzz-network-parser/directives.network @@ -381,12 +381,18 @@ Id= Parent= Handle= DefaultClass= +RateToQuantum= [HierarchyTokenBucketClass] Parent= ClassId= Priority= +QuantumBytes= +MTUBytes= +OverheadBytes= Rate= CeilRate= +BufferBytes= +CeilBufferBytes= [BFIFO] Parent= Handle= diff --git a/test/test-network/conf/25-qdisc-clsact-and-htb.network b/test/test-network/conf/25-qdisc-clsact-and-htb.network index 0d6815710c..f18e2f76d9 100644 --- a/test/test-network/conf/25-qdisc-clsact-and-htb.network +++ b/test/test-network/conf/25-qdisc-clsact-and-htb.network @@ -12,13 +12,19 @@ Parent=clsact Parent=root Handle=0002 DefaultClass=30 +RateToQuantum=20 [HierarchyTokenBucketClass] Parent=root ClassId=0002:0030 Priority=1 +QuantumBytes=4000 +MTUBytes=1700 +OverheadBytes=100 Rate=1M +BufferBytes=123456 CeilRate=0.5M +CeilBufferBytes=123457 [NetworkEmulator] Parent=2:30 diff --git a/test/test-network/systemd-networkd-tests.py b/test/test-network/systemd-networkd-tests.py index f059bc90f1..c48163b055 100755 --- a/test/test-network/systemd-networkd-tests.py +++ b/test/test-network/systemd-networkd-tests.py @@ -2420,7 +2420,7 @@ class NetworkdNetworkTests(unittest.TestCase, Utilities): self.assertRegex(output, 'qdisc pfifo_fast 3c: parent 2:3c') - output = check_output('tc class show dev dummy98') + output = check_output('tc -d class show dev dummy98') print(output) self.assertRegex(output, 'class htb 2:30 root leaf 30:') self.assertRegex(output, 'class htb 2:31 root leaf 31:') @@ -2435,7 +2435,9 @@ class NetworkdNetworkTests(unittest.TestCase, Utilities): self.assertRegex(output, 'class htb 2:3a root leaf 3a:') self.assertRegex(output, 'class htb 2:3b root leaf 3b:') self.assertRegex(output, 'class htb 2:3c root leaf 3c:') - self.assertRegex(output, 'prio 1 rate 1Mbit ceil 500Kbit') + self.assertRegex(output, 'prio 1 quantum 4000 rate 1Mbit overhead 100 ceil 500Kbit') + self.assertRegex(output, 'burst 123456') + self.assertRegex(output, 'cburst 123457') def test_qdisc2(self): copy_unit_to_networkd_unit_path('25-qdisc-drr.network', '12-dummy.netdev', |