Skip to content

Commit

Permalink
Updated test
Browse files Browse the repository at this point in the history
metapool package now stores boolean values in Bioinformatics section as
bool rather than string. Hence, the conversion step in mg-scripts and
associated test have been removed.
  • Loading branch information
charles-cowart committed Jul 3, 2024
1 parent 4057406 commit c781111
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 37 deletions.
12 changes: 0 additions & 12 deletions sequence_processing_pipeline/NuQCJob.py
Original file line number Diff line number Diff line change
Expand Up @@ -383,18 +383,6 @@ def _process_sample_sheet(self):
# the ordering of the rows will be preserved in the order of the list.
lst = bioinformatics.to_dict('records')

# convert true/false and yes/no strings to true boolean values.
for record in lst:
# the subset of columns that should be either True or False.
for key in ['BarcodesAreRC', 'HumanFiltering']:
val = record[key].strip()
if val == 'True':
record[key] = True
elif val == 'False':
record[key] = False
else:
raise ValueError(f"'{val}' is not a valid value for {key}")

# human-filtering jobs are scoped by project. Each job requires
# particular knowledge of the project.
return {'chemistry': chemistry,
Expand Down
24 changes: 0 additions & 24 deletions sequence_processing_pipeline/tests/test_NuQCJob.py
Original file line number Diff line number Diff line change
Expand Up @@ -966,30 +966,6 @@ def test_nuqcjob_creation(self):
self.pmls_path,
)

with self.assertRaisesRegex(
ValueError, "'FALSE' is not a valid value" " for HumanFiltering"
):
NuQCJob(
self.fastq_root_path,
self.output_path,
self.bad_sheet_bools_path,
self.mmi_db_paths,
"queue_name",
1,
1440,
"8",
"fastp",
"minimap2",
"samtools",
[],
self.qiita_job_id,
1000,
"",
self.movi_path,
self.gres_value,
self.pmls_path,
)

def test_error_msg_from_logs(self):
job = NuQCJob(
self.fastq_root_path,
Expand Down
3 changes: 2 additions & 1 deletion sequence_processing_pipeline/tests/test_Pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -2202,7 +2202,8 @@ def test_get_sample_names(self):
def test_get_project_info(self):
exp_proj_info = [
{'project_name': 'ABTX_20230208_ABTX_11052',
'qiita_id': '11052'}]
'qiita_id': '11052',
'contains_replicates': False}]

exp_project_names = ['ABTX_20230208_ABTX_11052']

Expand Down

0 comments on commit c781111

Please sign in to comment.