Exemplo n.º 1
0
 def test_check_fastq_strand_outputs_singlecell_missing(self):
     """
     check_fastq_strand_outputs: fastq_strand.py output missing (singlecell)
     """
     # Make mock analysis project
     p = MockAnalysisProject("PJB", (
         "PJB1_S1_R1_001.fastq.gz",
         "PJB1_S1_R2_001.fastq.gz",
     ),
                             metadata={'Organism': 'Human'})
     p.create(top_dir=self.wd)
     project = AnalysisProject("PJB", os.path.join(self.wd, "PJB"))
     # Make fastq_strand.conf
     fastq_strand_conf = os.path.join(project.dirn, "fastq_strand.conf")
     with open(fastq_strand_conf, 'w') as fp:
         fp.write("")
     # Check the outputs
     self.assertEqual(
         check_fastq_strand_outputs(project,
                                    "qc",
                                    fastq_strand_conf,
                                    qc_protocol="singlecell"),
         [
             (os.path.join(project.fastq_dir, "PJB1_S1_R2_001.fastq.gz"), ),
         ])
Exemplo n.º 2
0
 def test_check_fastq_strand_outputs_standardSE_present(self):
     """
     check_fastq_strand_outputs: fastq_strand.py output present (standardSE)
     """
     # Make mock analysis project
     p = MockAnalysisProject("PJB", ("PJB1_S1_R1_001.fastq.gz", ),
                             metadata={'Organism': 'Human'})
     p.create(top_dir=self.wd)
     project = AnalysisProject("PJB", os.path.join(self.wd, "PJB"))
     UpdateAnalysisProject(project).add_qc_outputs(
         protocol="standardSE",
         include_fastq_strand=True,
         include_multiqc=False)
     fastq_strand_conf = os.path.join(project.dirn, "fastq_strand.conf")
     # Check the outputs
     self.assertEqual(
         check_fastq_strand_outputs(project,
                                    "qc",
                                    fastq_strand_conf,
                                    qc_protocol="standardSE"), [])