[PATCH 15/35] virshtest: Drop support for testing against hardcoded strings

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

 



Now that all tests were converted, this is no longer needed.

Signed-off-by: Peter Krempa <pkrempa@xxxxxxxxxx>
---
 tests/virshtest.c | 14 +++-----------
 1 file changed, 3 insertions(+), 11 deletions(-)

diff --git a/tests/virshtest.c b/tests/virshtest.c
index 02bfb363c4..926f919d8d 100644
--- a/tests/virshtest.c
+++ b/tests/virshtest.c
@@ -36,7 +36,6 @@ static void testFilterLine(char *buffer,

 static int
 testCompareOutputLit(const char *expectFile,
-                     const char *expectData,
                      const char *filter,
                      const char *const argv[])
 {
@@ -64,15 +63,8 @@ testCompareOutputLit(const char *expectFile,
     if (filter)
         testFilterLine(actual, filter);

-    if (expectData) {
-        if (virTestCompareToString(expectData, actual) < 0)
-            return -1;
-    }
-
-    if (expectFile) {
-        if (virTestCompareToFileFull(actual, expectFile, false) < 0)
-            return -1;
-    }
+    if (virTestCompareToFileFull(actual, expectFile, false) < 0)
+        return -1;

     return 0;
 }
@@ -103,7 +95,7 @@ static int testCompare(const void *data)
                                   abs_srcdir, info->testname);
     }

-    return testCompareOutputLit(outfile, NULL, info->filter, info->argv);
+    return testCompareOutputLit(outfile, info->filter, info->argv);
 }


-- 
2.44.0
_______________________________________________
Devel mailing list -- devel@xxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxx




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux