Wait for all flows to be deleted before attempting to trigger a packet-in
diff --git a/tests/basic.py b/tests/basic.py
index ab97fed..ac4d89f 100644
--- a/tests/basic.py
+++ b/tests/basic.py
@@ -206,6 +206,7 @@
 
         rc = delete_all_flows(self.controller, basic_logger)
         self.assertEqual(rc, 0, "Failed to delete all flows")
+        do_barrier(self.controller)
 
         for of_port in basic_port_map.keys():
             basic_logger.info("PKT IN test, port " + str(of_port))