From 1760177d67463ce66747bbe707456811ec05f3d0 Mon Sep 17 00:00:00 2001 From: Giovanni Torres Date: Fri, 29 Dec 2017 12:08:25 -0500 Subject: [PATCH] Added checks for all other supported distributions. --- tests/check_distributions.bats | 57 ++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 tests/check_distributions.bats diff --git a/tests/check_distributions.bats b/tests/check_distributions.bats new file mode 100644 index 0000000..c60a2fa --- /dev/null +++ b/tests/check_distributions.bats @@ -0,0 +1,57 @@ +#!/usr/bin/env bats + +VMNAME=batstestvm + +function create_test_vm () +{ + local -r var="$1" + run kvm-install-vm create -t ${var} ${VMNAME}-${var} + [ "$status" -eq 0 ] +} + +function remove_test_vm () +{ + local -r var="$1" + run kvm-install-vm remove ${VMNAME}-${var} + [ "$status" -eq 0 ] +} + +@test "Install VM (CentOS 7 Atomic) - $VMNAME-centos7-atomic" { + create_test_vm centos7-atomic +} + +@test "Delete VM (CentOS 7 Atomic) - $VMNAME-centos7-atomic" { + remove_test_vm centos7-atomic +} + +@test "Install VM (Fedora 26 Atomic) - $VMNAME-fedora26-atomic" { + create_test_vm fedora26-atomic +} + +@test "Delete VM (Fedora 26 Atomic) - $VMNAME-fedora26-atomic" { + remove_test_vm fedora26-atomic +} + +@test "Install VM (Fedora 26) - $VMNAME-fedora26" { + create_test_vm fedora26 +} + +@test "Delete VM (Fedora 26) - $VMNAME-fedora26" { + remove_test_vm fedora26 +} + +@test "Install VM (Ubuntu 16.04) - $VMNAME-ubuntu1604" { + create_test_vm ubuntu1604 +} + +@test "Delete VM (Ubuntu 16.04) - $VMNAME-ubuntu1604" { + remove_test_vm ubuntu1604 +} + +@test "Install VM (Debian 9) - $VMNAME-debian9" { + create_test_vm debian9 +} + +@test "Delete VM (Debian 9) - $VMNAME-debian9" { + remove_test_vm debian9 +}