[Box Backup-commit] COMMIT r2508 - box/trunk/lib/common

boxbackup-dev@boxbackup.org boxbackup-dev@boxbackup.org
Sun, 26 Apr 2009 12:55:16 +0100 (BST)


Author: chris
Date: 2009-04-26 12:55:14 +0100 (Sun, 26 Apr 2009)
New Revision: 2508

Modified:
   box/trunk/lib/common/Test.h
Log:
Show expected and actual return codes from shell commands in tests.


Modified: box/trunk/lib/common/Test.h
===================================================================
--- box/trunk/lib/common/Test.h	2009-04-23 00:50:42 UTC (rev 2507)
+++ box/trunk/lib/common/Test.h	2009-04-26 11:55:14 UTC (rev 2508)
@@ -18,14 +18,14 @@
 #define BBSTORED        "..\\..\\bin\\bbstored\\bbstored.exe"
 #define BBACKUPQUERY    "..\\..\\bin\\bbackupquery\\bbackupquery.exe"
 #define BBSTOREACCOUNTS "..\\..\\bin\\bbstoreaccounts\\bbstoreaccounts.exe"
-#define TEST_RETURN(actual, expected) TEST_THAT(actual == expected);
+#define TEST_RETURN(actual, expected) TEST_EQUAL(expected, actual);
 #else
 #define BBACKUPCTL      "../../bin/bbackupctl/bbackupctl"
 #define BBACKUPD        "../../bin/bbackupd/bbackupd"
 #define BBSTORED        "../../bin/bbstored/bbstored"
 #define BBACKUPQUERY    "../../bin/bbackupquery/bbackupquery"
 #define BBSTOREACCOUNTS "../../bin/bbstoreaccounts/bbstoreaccounts"
-#define TEST_RETURN(actual, expected) TEST_THAT(actual == expected*256);
+#define TEST_RETURN(actual, expected) TEST_EQUAL(expected << 8, actual);
 #endif
 
 extern int failures;