+def make_qseqs(bustard_dir, in_temp=True):
+ """
+ Fill gerald directory with qseq files
+ """
+ # 42BRJ 8 1 0039 happened to be a better than usual tile, in that there
+ # was actually sequence at the start
+ source = os.path.join(TESTDATA_DIR, '42BRJAAXX_8_1_0039_qseq.txt')
+ destdir = bustard_dir
+ if not os.path.isdir(destdir):
+ os.mkdir(destdir)
+
+ for lane in LANE_LIST:
+ for tile in TILE_LIST:
+ destination = os.path.join(bustard_dir, 's_%d_1_%04d_qseq.txt' % (lane, tile))
+ shutil.copy(source, destination)
+
+ make_matrix_dir(bustard_dir)
+ make_phasing_dir(bustard_dir)
+
+ summary_source = os.path.join(TESTDATA_DIR, '42BRJAAXX_BustardSummary.xml')
+ summary_dest = os.path.join(bustard_dir, 'BustardSummary.xml')
+ shutil.copy(summary_source, summary_dest)
+
+ return destdir
+
+def make_scores(gerald_dir, in_temp=True):
+ """
+ Fill gerald directory with score temp files
+ will create the directory if it doesn't exist.
+ """
+ source = os.path.join(TESTDATA_DIR, 's_1_0001_score.txt')
+ destdir = gerald_dir
+ if in_temp:
+ destdir = os.path.join(destdir, 'Temp')
+ if not os.path.isdir(destdir):
+ os.mkdir(destdir)
+
+ for lane in LANE_LIST:
+ for tile in TILE_LIST:
+ destination = os.path.join(destdir, 's_%d_%04d_score.txt' % (lane, tile))
+ shutil.copy(source, destination)
+
+ return destdir
+
+def make_matrix_dir(bustard_dir):
+ """
+ Create several matrix files in <bustard_dir>/Matrix/