Changeset 9490


Ignore:
Timestamp:
Jan 22, 2015, 4:26:49 PM (10 years ago)
Author:
steve
Message:

cleaned up file folder

Location:
trunk/anuga_core/source/anuga
Files:
1 added
1 deleted
9 edited

Legend:

Unmodified
Added
Removed
  • trunk/anuga_core/source/anuga/file/test/test_read_sww.py

    r9488 r9490  
    1111
    1212
    13 import sww
     13import anuga.file.sww as sww
    1414               
    1515
     
    2525
    2626    def tearDown(self):
    27         pass
     27        for filename in ['read_sww_test0.sww', 'read_sww_test_c0.sww']:
     28            try:
     29                os.remove(filename)
     30            except:
     31                pass
    2832
    2933    def test_read_sww(self):
     
    3943            rectangular_cross
    4044        from anuga.shallow_water.shallow_water_domain import Domain
    41         from boundaries import Reflective_boundary
     45        from anuga import Reflective_boundary
    4246        from anuga.abstract_2d_finite_volumes.generic_boundary_conditions\
    4347                            import Dirichlet_boundary, Time_boundary
  • trunk/anuga_core/source/anuga/file/test/test_sww.py

    r9488 r9490  
    55
    66from anuga.coordinate_transforms.geo_reference import Geo_reference
    7 from csv_file import load_csv_as_array, load_csv_as_dict
     7from anuga.file.csv_file import load_csv_as_array, load_csv_as_dict
    88from anuga.abstract_2d_finite_volumes.mesh_factory import rectangular
    99from anuga.shallow_water.shallow_water_domain import Domain
    10 from sww import load_sww_as_domain, weed, get_mesh_and_quantities_from_file, \
     10from anuga.file.sww import load_sww_as_domain, weed, get_mesh_and_quantities_from_file, \
    1111                Write_sww
    1212from anuga.file.netcdf import NetCDFFile
     
    2929
    3030    def tearDown(self):
    31         pass
     31        for filename in ['test_get_mesh_and_quantities_from_unique_vertices_sww_file.sww', \
     32                         'test_get_mesh_and_quantities_from_sww_file.sww']:
     33            try:
     34                os.remove(filename)
     35            except:
     36                pass
    3237       
    3338    def test_sww2domain1(self):
     
    3540        #Create a test domain, and evolve and save it.
    3641        ################################################
    37         from mesh_factory import rectangular
     42        #from mesh_factory import rectangular
    3843
    3944        #Create basic mesh
     
    186191
    187192        # Setup
    188         from mesh_factory import rectangular
     193        #from mesh_factory import rectangular
    189194
    190195        # Create basic mesh (100m x 5m)
     
    257262
    258263        # Setup
    259         from mesh_factory import rectangular
     264        #from mesh_factory import rectangular
    260265
    261266        # Create basic mesh (100m x 5m)
     
    552557if __name__ == "__main__":
    553558    suite = unittest.makeSuite(Test_sww, 'test')
    554     runner = unittest.TextTestRunner(verbosity=2)
     559    runner = unittest.TextTestRunner(verbosity=1)
    555560    runner.run(suite)
  • trunk/anuga_core/source/anuga/file/test/test_ungenerate.py

    r9488 r9490  
    77
    88from anuga.pmesh.mesh import Vertex, Segment, Mesh
    9 from ungenerate import load_ungenerate
     9from anuga.file.ungenerate import load_ungenerate
    1010
    1111class ungenerateTestCase(unittest.TestCase):
     
    1414   
    1515    def tearDown(self):
    16         pass
     16        for filename in ['swamp.tsh']:
     17            try:
     18                os.remove(filename)
     19            except:
     20                pass
    1721       
    1822    def test_ungenerateFileLoading(self):
  • trunk/anuga_core/source/anuga/file/test/test_urs.py

    r9488 r9490  
    11import unittest
    22import numpy as num
    3 
    4 from urs import calculate_boundary_points, save_boundary_as_urs
     3import os
     4
     5from anuga.file.urs import calculate_boundary_points, save_boundary_as_urs
    56from anuga.coordinate_transforms.redfearn import degminsec2decimal_degrees
    67from anuga.geospatial_data.geospatial_data import Geospatial_data
     
    1213
    1314    def tearDown(self):
    14         pass
     15        for filename in ['swamp.tsh']:
     16            try:
     17                os.remove(filename)
     18            except:
     19                pass
    1520       
    1621    def test_URS_points_needed(self):
  • trunk/anuga_core/source/anuga/file_conversion/test/test_urs2sts.py

    r9476 r9490  
    2929
    3030# Allow us to use helper methods from this test.
    31 from anuga.file.test_mux import Test_Mux
     31from anuga.file.test.test_mux import Test_Mux
    3232
    3333class Test_Urs2Sts(Test_Mux):
  • trunk/anuga_core/source/anuga/file_conversion/test/test_urs2sww.py

    r9478 r9490  
    2626
    2727# use helper methods from other unit test
    28 from anuga.file.test_mux import Test_Mux
     28from anuga.file.test.test_mux import Test_Mux
    2929
    3030
  • trunk/anuga_core/source/anuga/shallow_water/test/test_data_manager.py

    r9457 r9490  
    2121
    2222
     23from anuga.abstract_2d_finite_volumes.mesh_factory import rectangular
    2324from anuga.anuga_exceptions import ANUGAError
    2425from anuga.file.sww import SWW_file
     
    6162
    6263# use helper methods from other unit test
    63 from anuga.file.test_mux import Test_Mux
     64from anuga.file.test.test_mux import Test_Mux
    6465
    6566
     
    7374    def setUp(self):
    7475        import time
    75         from mesh_factory import rectangular
     76        #from mesh_factory import rectangular
    7677       
    7778        self.verbose = Test_Data_Manager.verbose
  • trunk/anuga_core/source/anuga/test_all.py

    r8819 r9490  
    110110    print
    111111    print 'Testing path: %s' % path
    112 
     112   
     113    common_dir = os.path.dirname(path)
     114    common_dir_length = len(common_dir)
     115    #print common_dir, common_dir_length
     116   
    113117    # get the terminal width
    114118    term_width = terminal_width()
     
    122126    # get all test_*.py and enclosing directories
    123127    test_files, path_files = get_test_files(path)
     128    #print path_files
    124129    path_files.sort()
    125130
     
    127132    files.sort()        # Ensure same order on all platforms
    128133
     134    def my_filter(pathname):
     135       
     136        return pathname[common_dir_length+1:]
     137   
    129138    print
    130139    print 'Paths searched:'
    131     list_names(path_files, os.path.basename, page_width=term_width)
     140    list_names(path_files, my_filter, page_width=term_width)
    132141
    133142    print   
  • trunk/anuga_core/source/anuga/utilities/test/test_spatialInputUtil.py

    r9435 r9490  
    1111import anuga
    1212import numpy
     13import os
    1314from anuga.shallow_water.shallow_water_domain import Domain
    1415from anuga.utilities import plot_utils as util
     
    3031
    3132    def tearDown(self):
    32         pass
     33        for file in ['PointData_TestData.tif']:
     34            try:
     35                os.remove(file)
     36            except:
     37                pass       
    3338
    3439    def make_me_a_tif(self):
Note: See TracChangeset for help on using the changeset viewer.