Index: /anuga_validation/automated_validation_tests/okushiri_tank_validation/compare_timeseries_with_measures.py
===================================================================
--- /anuga_validation/automated_validation_tests/okushiri_tank_validation/compare_timeseries_with_measures.py	(revision 3918)
+++ /anuga_validation/automated_validation_tests/okushiri_tank_validation/compare_timeseries_with_measures.py	(revision 3919)
@@ -21,5 +21,8 @@
     plotting = True
 
-#plotting = False
+# No plotting for automated unittest (unless one wishes to run
+# this manually and look at the outputs)
+plotting = False
+
 
 #-------------------------
@@ -39,5 +42,5 @@
 
 
-# Results from lwru2_variable_mesh.sww
+# Results from lwru2_variable_mesh.sww (aug 2005)
 #
 #Validating Boundary
@@ -300,5 +303,5 @@
         pass
 
-    assert res-eps < expected_covariance[name] < res+eps
+    assert res-eps <= expected_covariance[name] <= res+eps
     
     
@@ -320,5 +323,5 @@
 
 
-    assert res-eps < expected_difference[name] < res+eps
+    assert res-eps <= expected_difference[name] <= res+eps
 
     # Extrema
@@ -337,5 +340,5 @@
         pass
 
-    assert res-eps < expected_maximum_diff[name] < res+eps    
+    assert res-eps <= expected_maximum_diff[name] <= res+eps    
 
     
@@ -354,5 +357,5 @@
         pass
 
-    assert res-eps < expected_minimum_diff[name] < res+eps
+    assert res-eps <= expected_minimum_diff[name] <= res+eps
     
 
@@ -374,5 +377,5 @@
         pass
     
-    assert res-eps < expected_argmax_timelag[name] < res+eps
+    assert res-eps <= expected_argmax_timelag[name] <= res+eps
 
     i0 = argmin(observed_timeseries)
@@ -391,5 +394,5 @@
         pass
 
-    assert res-eps < expected_argmin_timelag[name] < res+eps
+    assert res-eps <= expected_argmin_timelag[name] <= res+eps
 
 
Index: /anuga_validation/automated_validation_tests/okushiri_tank_validation/project.py
===================================================================
--- /anuga_validation/automated_validation_tests/okushiri_tank_validation/project.py	(revision 3918)
+++ /anuga_validation/automated_validation_tests/okushiri_tank_validation/project.py	(revision 3919)
@@ -17,5 +17,5 @@
 
 # Model output
-output_filename = 'okushiri_auta_validation.sww'
+output_filename = 'okushiri_auto_validation.sww'
 
 
Index: /anuga_validation/automated_validation_tests/okushiri_tank_validation/validate_okushiri.py
===================================================================
--- /anuga_validation/automated_validation_tests/okushiri_tank_validation/validate_okushiri.py	(revision 3918)
+++ /anuga_validation/automated_validation_tests/okushiri_tank_validation/validate_okushiri.py	(revision 3919)
@@ -3,17 +3,54 @@
 """
 
-
+import unittest
 import os
 
-# FIXME: Make into unit test
 
-# FIXME: Redirect stdout and stderr
+class Test_Okushiri(unittest.TestCase):
+    def setUp(self):
 
-s = 'create_okushiri.py'
-os.system('python %s ' %s)
+        # Remove garbage
+        for file in os.listdir('.'):
+            if file.endswith('.stdout') or\
+               file.endswith('.sww') or\
+               file.endswith('.msh'):
+                os.remove(file)
+                
 
-s = 'run_okushiri.py'
-os.system('python %s ' %s)
+        #print
+        s = 'create_okushiri.py'
+        #print s
+        res = os.system('python %s > create_okushiri.stdout' %s)
+        assert res == 0
 
-s = 'compare_timeseries_with_measures.py'
-os.system('python %s ' %s)
+        s = 'run_okushiri.py'
+        #print s        
+        res = os.system('python %s > run_okushiri.stdout' %s)        
+        assert res == 0
+        
+
+    def tearDown(self):
+        pass
+
+    #def test_creation_of_mesh(self):
+    #    s = 'create_okushiri.py'
+    #    os.system('python %s > create_okushiri.stdout' %s)
+
+    #def test_that_simulation_can_run(self):
+    #    s = 'run_okushiri.py'
+    #    os.system('python %s > run_okushiri.stdout' %s)
+
+    def test_that_output_is_as_expected(self):    
+        s = 'compare_timeseries_with_measures.py'
+        #print s
+        res = os.system('python %s > compare_timeseries_with_measures.stdout'\
+                        %s)
+        assert res == 0
+
+
+
+#-------------------------------------------------------------
+if __name__ == "__main__":
+    suite = unittest.makeSuite(Test_Okushiri,'test')
+    runner = unittest.TextTestRunner(verbosity=2)
+    runner.run(suite)
