Rich Lane | 1568b65 | 2013-01-04 16:53:13 -0800 | [diff] [blame] | 1 | """ |
| 2 | These tests require a switch that drops packet-ins. |
| 3 | """ |
| 4 | |
| 5 | import logging |
| 6 | |
| 7 | from oftest import config |
| 8 | import oftest.controller as controller |
Rich Lane | d7b0ffa | 2013-03-08 15:53:42 -0800 | [diff] [blame] | 9 | import ofp |
Rich Lane | 1568b65 | 2013-01-04 16:53:13 -0800 | [diff] [blame] | 10 | import oftest.dataplane as dataplane |
Rich Lane | 1568b65 | 2013-01-04 16:53:13 -0800 | [diff] [blame] | 11 | import oftest.base_tests as base_tests |
| 12 | |
| 13 | from oftest.testutils import * |
| 14 | |
| 15 | @nonstandard |
| 16 | class PacketInDefaultDrop(base_tests.SimpleDataPlane): |
| 17 | """ |
| 18 | Verify that packet-ins are not received. |
| 19 | """ |
| 20 | |
| 21 | def runTest(self): |
| 22 | delete_all_flows(self.controller) |
| 23 | do_barrier(self.controller) |
| 24 | |
| 25 | for of_port in config["port_map"].keys(): |
Rich Lane | 4c504f3 | 2013-06-07 17:24:14 -0700 | [diff] [blame] | 26 | pkt = str(simple_tcp_packet()) |
| 27 | self.dataplane.send(of_port, pkt) |
| 28 | verify_no_packet_in(self, pkt, of_port) |