diff options
author | IWASE Yusuke <iwase.yusuke0@gmail.com> | 2015-12-22 11:49:23 +0900 |
---|---|---|
committer | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2015-12-22 13:50:27 +0900 |
commit | d736b830b966c349489fa4079cbac05284abcedc (patch) | |
tree | e67d7b935781938fb42a5bf3e6ec87b422849390 | |
parent | 83d529a979f35738e220ab33e42ad447ace0b95d (diff) |
lib/ofctl: Add test cases for ofctl_v1_0
TODO: Add test cases for the other messages after adding test cases
for ofproto/test_parser.
Signed-off-by: IWASE Yusuke <iwase.yusuke0@gmail.com>
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
-rw-r--r-- | ryu/tests/unit/lib/ofctl_json/of10/1-2-ofp_flow_mod.packet.json | 23 | ||||
-rw-r--r-- | ryu/tests/unit/lib/test_ofctl.py | 7 |
2 files changed, 30 insertions, 0 deletions
diff --git a/ryu/tests/unit/lib/ofctl_json/of10/1-2-ofp_flow_mod.packet.json b/ryu/tests/unit/lib/ofctl_json/of10/1-2-ofp_flow_mod.packet.json new file mode 100644 index 00000000..cc0b13d9 --- /dev/null +++ b/ryu/tests/unit/lib/ofctl_json/of10/1-2-ofp_flow_mod.packet.json @@ -0,0 +1,23 @@ +{ + "cmd": 0, + "flow": { + "actions": [ + { + "type": "OUTPUT", + "max_len": 65535, + "port": 6 + } + ], + "buffer_id": 65535, + "command": 0, + "cookie": 0, + "flags": 0, + "hard_timeout": 0, + "idle_timeout": 0, + "match": { + "dl_dst": "f2:0b:a4:7d:f8:ea" + }, + "out_port": 65532, + "priority": 123 + } +} diff --git a/ryu/tests/unit/lib/test_ofctl.py b/ryu/tests/unit/lib/test_ofctl.py index 949a548c..adb2719f 100644 --- a/ryu/tests/unit/lib/test_ofctl.py +++ b/ryu/tests/unit/lib/test_ofctl.py @@ -111,6 +111,13 @@ def _add_tests(): } _test_cases = { + 'of10': [ + { + 'method': ofctl_v1_0.mod_flow_entry, + 'request': '1-2-ofp_flow_mod.packet.json', + 'reply': None + }, + ], 'of12': [ { 'method': ofctl_v1_2.get_desc_stats, |