For pipeline 1.1rc1 or 1.3.2, look for the matrix files in the bustard dir
[htsworkflow.git] / htsworkflow / pipelines / test / simulate_runfolder.py
index 53c7301483eae6b009a3dd92b4af8c29d94c260b..455d8c1b73bdb537372d710c50f4ca3f5ef980a3 100644 (file)
@@ -15,14 +15,14 @@ def make_firecrest_dir(data_dir, version="1.9.2", start=1, stop=37):
     os.mkdir(firecrest_dir)
     return firecrest_dir
     
-def make_ipar_dir(data_dir):
+def make_ipar_dir(data_dir, version='1.01'):
     """
     Construct an artificial ipar parameter file and directory
     """
     ipar1_01_file = os.path.join(TESTDATA_DIR, 'IPAR1.01.params')
     shutil.copy(ipar1_01_file, os.path.join(data_dir, '.params'))
 
-    ipar_dir = os.path.join(data_dir, 'IPAR_1.01')
+    ipar_dir = os.path.join(data_dir, 'IPAR_%s' % (version,))
     if not os.path.exists(ipar_dir):
       os.mkdir(ipar_dir)
     return ipar_dir
@@ -44,6 +44,11 @@ def make_flowcell_id(runfolder_dir, flowcell_id=None):
     f.write(config)
     f.close()
 
+def make_bustard_config132(gerald_dir):
+    source = os.path.join(TESTDATA_DIR, 'bustard-config132.xml')
+    destination = os.path.join(gerald_dir, 'config.xml')
+    shutil.copy(source, destination)
+
 def make_matrix(matrix_filename):
     contents = """# Auto-generated frequency response matrix
 > A