[Libguestfs] [PATCH 3/3] fish: Add regression test for RHBZ#1175196.

Richard W.M. Jones rjones at redhat.com
Wed Dec 17 14:04:30 UTC 2014


---
 tests/regressions/Makefile.am    |  2 ++
 tests/regressions/rhbz1175196.sh | 30 ++++++++++++++++++++++++++++++
 2 files changed, 32 insertions(+)
 create mode 100755 tests/regressions/rhbz1175196.sh

diff --git a/tests/regressions/Makefile.am b/tests/regressions/Makefile.am
index de97526..72d26da 100644
--- a/tests/regressions/Makefile.am
+++ b/tests/regressions/Makefile.am
@@ -42,6 +42,7 @@ EXTRA_DIST = \
 	rhbz1044014.xml \
 	rhbz1054761.sh \
 	rhbz1091803.sh \
+	rhbz1175196.sh \
 	test-noexec-stack.pl
 
 TESTS = \
@@ -66,6 +67,7 @@ TESTS = \
 	rhbz1054761.sh \
 	rhbz1055452 \
 	rhbz1091803.sh \
+	rhbz1175196.sh \
 	test-noexec-stack.pl
 
 if HAVE_LIBVIRT
diff --git a/tests/regressions/rhbz1175196.sh b/tests/regressions/rhbz1175196.sh
new file mode 100755
index 0000000..06f6c24
--- /dev/null
+++ b/tests/regressions/rhbz1175196.sh
@@ -0,0 +1,30 @@
+#!/bin/bash -
+# libguestfs
+# Copyright (C) 2014 Red Hat Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+# Regression test for:
+# https://bugzilla.redhat.com/show_bug.cgi?id=1175196
+# Parse 'LIBGUESTFS_TRACE=0' in the environment.
+
+set -e
+export LANG=C
+
+if [ "$(guestfish setenv LIBGUESTFS_TRACE 1 : parse-environment : get-trace : setenv LIBGUESTFS_TRACE 0 : parse-environment : get-trace)" != "true
+false" ]; then
+    echo "$0: unexpected output from test"
+    exit 1
+fi
-- 
2.1.0




More information about the Libguestfs mailing list