From 07c82cd3e472c7be0239349dfbecab2f9869a03a Mon Sep 17 00:00:00 2001 From: Jonatan Schlag Date: Tue, 7 Aug 2018 19:15:34 +0200 Subject: [PATCH] Add new test zone-new-bridge This test checks if we can create a new zone of type bridge. Signed-off-by: Jonatan Schlag --- Makefile.am | 15 +++++++++------ test/nitsi/test/zone-new-bridge/.gitignore | 3 +++ test/nitsi/test/zone-new-bridge/recipe | 9 +++++++++ test/nitsi/test/zone-new-bridge/settings.in | 9 +++++++++ 4 files changed, 30 insertions(+), 6 deletions(-) create mode 100644 test/nitsi/test/zone-new-bridge/.gitignore create mode 100644 test/nitsi/test/zone-new-bridge/recipe create mode 100644 test/nitsi/test/zone-new-bridge/settings.in diff --git a/Makefile.am b/Makefile.am index 4a0c4ea1..1ea715e0 100644 --- a/Makefile.am +++ b/Makefile.am @@ -601,21 +601,24 @@ CLEANFILES += \ NITSI_TESTS = \ test/nitsi/test/hello-world \ test/nitsi/test/make-check \ - test/nitsi/test/raw-device-get-by-mac + test/nitsi/test/raw-device-get-by-mac \ + test/nitsi/test/zone-new-bridge EXTRA_DIST += \ test/nitsi/test/hello-world/recipe \ test/nitsi/test/hello-world/settings \ test/nitsi/test/make-check/recipe.in \ - test/nitsi/test/make-check/settings.in - test/nitsi/test/raw-device-get-by-mac/recipe\ - test/nitsi/test/raw-device-get-by-mac/settings.in - + test/nitsi/test/make-check/settings.in \ + test/nitsi/test/raw-device-get-by-mac/recipe \ + test/nitsi/test/raw-device-get-by-mac/settings.in \ + test/nitsi/test/zone-new-bridge/recipe \ + test/nitsi/test/zone-new-bridge/settings.in CLEANFILES += \ test/nitsi/test/make-check/recipe \ test/nitsi/test/make-check/settings \ - test/nitsi/test/raw-device-get-by-mac/settings + test/nitsi/test/raw-device-get-by-mac/settings \ + test/nitsi/test/zone-new-bridge/settings NITSI_ENVIRONMENT = diff --git a/test/nitsi/test/zone-new-bridge/.gitignore b/test/nitsi/test/zone-new-bridge/.gitignore new file mode 100644 index 00000000..8a9bd77f --- /dev/null +++ b/test/nitsi/test/zone-new-bridge/.gitignore @@ -0,0 +1,3 @@ +/log +/recipe.log +/settings diff --git a/test/nitsi/test/zone-new-bridge/recipe b/test/nitsi/test/zone-new-bridge/recipe new file mode 100644 index 00000000..d6dcfb76 --- /dev/null +++ b/test/nitsi/test/zone-new-bridge/recipe @@ -0,0 +1,9 @@ +include: ../../include/make-install +include: ../../include/network-settings +include: ../../include/network-reset +alice: network zone new upl0 bridge +# this returns zero if the device exists +alice: ip link show upl0 +alice: ls /sys/class/net/upl0 +# check that the config dir exists +alice: ls /etc/network/zones/upl0 diff --git a/test/nitsi/test/zone-new-bridge/settings.in b/test/nitsi/test/zone-new-bridge/settings.in new file mode 100644 index 00000000..207cfa05 --- /dev/null +++ b/test/nitsi/test/zone-new-bridge/settings.in @@ -0,0 +1,9 @@ +[GENERAL] +name = zone-new-bridge +description = This test checks if we can create a new zone of the type 'bridge' + +copy_from = ../../../../@PACKAGE_NAME@-@PACKAGE_VERSION@.tar.gz +copy_to = /root/ + +[VIRTUAL_ENVIRONMENT] +path = ../../virtual-environment/basic -- 2.39.2