[gnome-boxes] tests: Separate out box creation on system broker



commit 16fb26191b3bc7939e430a9abcb1c509621152c0
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date:   Mon Feb 2 15:51:45 2015 +0000

    tests: Separate out box creation on system broker
    
    Box creation on system broker and creating a connection to system broker
    are two different steps really so lets separate them out from each other.

 tests/steps/system-broker.py |    9 +++++++--
 tests/system-broker.feature  |    8 ++++++++
 2 files changed, 15 insertions(+), 2 deletions(-)
---
diff --git a/tests/steps/system-broker.py b/tests/steps/system-broker.py
index 6ce0dac..4965547 100644
--- a/tests/steps/system-broker.py
+++ b/tests/steps/system-broker.py
@@ -3,11 +3,16 @@
 from __future__ import unicode_literals
 from behave import step
 
- step('Connect to system broker')
-def connect_to_filled_system_broker(context):
+ step('Create Core-5.3 box on system broker')
+def create_box_on_system_broker(context):
     context.execute_steps("""
         * Wait for "virt-install -q -r 128 --name Core-5.3 --nodisks --cdrom /tmp/Core-5.3.iso --os-type 
linux --accelerate --connect qemu:///system --wait 0" end
         * Wait for "sleep 10" end
+        """)
+
+ step('Connect to system broker')
+def connect_to_filled_system_broker(context):
+    context.execute_steps("""
         * Create new box from url "qemu:///system"
         * Wait for "sleep 1" end
         * Press "Create"
diff --git a/tests/system-broker.feature b/tests/system-broker.feature
index 431dc3a..73263d3 100644
--- a/tests/system-broker.feature
+++ b/tests/system-broker.feature
@@ -6,6 +6,7 @@ Feature: System Broker
 
   @connect_to_system_broker_machine
   Scenario: Connect to system broker
+    * Create Core-5.3 box on system broker
     * Connect to system broker
     Then Box "Core-5.3" "does" exist
     Then Go into "Core-5.3" box
@@ -14,6 +15,7 @@ Feature: System Broker
 
   @delete_system_broker_machine
   Scenario: Delete system broker machine
+    * Create Core-5.3 box on system broker
     * Connect to system broker
     * Select "Core-5.3" box
     * Press "Delete"
@@ -23,6 +25,7 @@ Feature: System Broker
 
   @reflect_delete_from_system_broker
   Scenario: System broker machine deleted from outside
+    * Create Core-5.3 box on system broker
     * Connect to system broker
     * Wait for "virsh -c qemu:///system destroy Core-5.3; virsh -c qemu:///system undefine Core-5.3" end
     Then Box "Core-5.3" "does not" exist
@@ -38,6 +41,7 @@ Feature: System Broker
 
   @undo_delete_system_broker_machine
   Scenario: Undo system broker machine delete
+    * Create Core-5.3 box on system broker
     * Connect to system broker
     * Select "Core-5.3" box
     * Press "Delete"
@@ -47,6 +51,7 @@ Feature: System Broker
 
   @pause_system_broker_box
   Scenario: Pause system broker box
+    * Create Core-5.3 box on system broker
     * Connect to system broker
     When Ping "Core-5.3"
     * Select "Core-5.3" box
@@ -56,6 +61,7 @@ Feature: System Broker
 
   @resume_system_broker_box
   Scenario: Resume system broker box
+    * Create Core-5.3 box on system broker
     * Connect to system broker
     * Select "Core-5.3" box
     * Press "Pause"
@@ -67,6 +73,7 @@ Feature: System Broker
 
   @force_shutdown_system_broker_machine
   Scenario: Force off system broker box
+    * Create Core-5.3 box on system broker
     * Connect to system broker
     * Select "Core-5.3" box
     * Press "Properties"
@@ -77,6 +84,7 @@ Feature: System Broker
 
   @system_broker_restart_persistence
   Scenario: System broker restart persistence
+    * Create Core-5.3 box on system broker
     * Connect to system broker
     * Quit Boxes
     * Start Boxes


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]