Ignore:
Timestamp:
15/12/08 16:49:46 (11 years ago)
Author:
cbyrom
Message:

Adjust test suite to become:
a) test environment (i.e. running as noseTest or individual unittest) agnostic;
and b) os agnostic - i.e. coping with different path separators.
Add additional documenation.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • exist/trunk/python/ndgutilstests/testconstants.py

    r4641 r4651  
    1616import ndgUtils.lib.existdbclient as dbc 
    1717from ndgUtils.models.Atom import Atom 
     18import os 
    1819 
    19 DBCONFIG_FILE = "exist.config" 
     20BASE_DIR = 'ndgutilstests' 
    2021 
    21 TEST_GRANULITE = '../testdata/example.granulite' 
     22curDir = os.getcwd() 
     23prefix = '' 
     24if not curDir.endswith(BASE_DIR): 
     25    prefix = '..' + os.sep 
     26     
     27TEST_DATA_DIR = prefix + 'testdata' + os.sep 
     28DBCONFIG_FILE = TEST_DATA_DIR + 'exist.config' 
     29TEST_GRANULITE = TEST_DATA_DIR + 'example.granulite' 
     30 
     31NDG_CONFIG_FILE = TEST_DATA_DIR + 'ndgDiscovery.config' 
     32DIF_FILE = TEST_DATA_DIR + 'dataent_NDSC_DIF.xml' 
     33 
    2234GRANULITE_TITLE = 'this is a new test granulite' 
    2335GRANULITE_TIME_AXIS = 'time0' 
    24 GRANULITE_CDML_DATASETID = 'hadgem1_dataset' 
     36GRANULITE_CDML_DATASETID = 'test_hadgem1_dataset' 
    2537GRANULITE_PROVIDER_ID = 'badc.nerc.ac.uk' 
    2638GRANULITE_DATASETID = 'calum_data_set' 
     
    145157              '/db/moles_support/granuleAtom/famous_control_month_granule.moles'] 
    146158 
    147 #t1 = '2792-12-16 0:0:0.0' 
    148 #t2 = '2992-11-16 0:0:0.0' 
    149  
    150159client = dbc.eXistDBClient(configFile = DBCONFIG_FILE, setUpDB = True) 
    151160 
Note: See TracChangeset for help on using the changeset viewer.