From 1dfa382e44bdb386136d84f3d7f67cfdb080fe16 Mon Sep 17 00:00:00 2001 From: Sean Dague Date: Tue, 11 Mar 2008 20:15:07 +0000 Subject: moving everything into OpenSim.TestSuite namespace --- OpenSim/TestSuite/Util.cs | 55 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 OpenSim/TestSuite/Util.cs (limited to 'OpenSim/TestSuite/Util.cs') diff --git a/OpenSim/TestSuite/Util.cs b/OpenSim/TestSuite/Util.cs new file mode 100644 index 0000000..edc2a54 --- /dev/null +++ b/OpenSim/TestSuite/Util.cs @@ -0,0 +1,55 @@ +using System; + +namespace OpenSim.TestSuite +{ + + public class Utils + { + enum Result { + Fail = 0, + Pass = 1, + Skip = 3 + } + + private static String ResultToString(Result r) + { + if (r == Result.Pass) + { + return "PASS"; + } + else if (r == Result.Fail) + { + return "FAIL"; + } + else if (r == Result.Skip) + { + return "SKIP"; + } + else + { + return "UNKNOWN"; + } + } + + + private static void TestResult(Result r, String msg) + { + System.Console.WriteLine("[{0}]: {1}", ResultToString(r), msg); + } + + public static void TestFail(String msg) + { + TestResult(Result.Fail, msg); + } + + public static void TestPass(String msg) + { + TestResult(Result.Pass, msg); + } + + public static void TestSkip(String msg) + { + TestResult(Result.Skip, msg); + } + } +} \ No newline at end of file -- cgit v1.1