Skip to content

Commit

Permalink
Merge pull request #550 from ptth222/511-testing-changes
Browse files Browse the repository at this point in the history
More changes
  • Loading branch information
terazus authored Mar 11, 2024
2 parents e5f6fd2 + 0f9214f commit 6d30dc2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion tests/isatab/test_isatab.py
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,7 @@ def test_isatab_dump_source_sample_char_quant(self):
s.process_sequence = [sample_collection_process]
s.samples.append(sample1)
i.studies = [s]
actual = isatab.dumps(i)
actual = replace_windows_newlines(isatab.dumps(i))
expected = """Source Name\tMaterial Type\tCharacteristics[organism]\tTerm Source REF\tTerm Accession Number\tCharacteristics[body weight]\tUnit\tTerm Source REF\tTerm Accession Number\tProtocol REF\tParameter Value[vessel]\tTerm Source REF\tTerm Accession Number\tParameter Value[storage temperature]\tUnit\tTerm Source REF\tTerm Accession Number\tSample Name\tCharacteristics[organism part]\tTerm Source REF\tTerm Accession Number\tCharacteristics[specimen mass]\tUnit\tTerm Source REF\tTerm Accession Number
source1\tspecimen\tHuman\tNCBITAXON\thttp://purl.bioontology.org/ontology/STY/T016\t72\tkilogram\tUO\thttp://purl.obolibrary.org/obo/UO_0000009\tsample collection\teppendorf tube\tOBI\tpurl.org\t-20\tdegree Celsius\tUO\thttp://purl.obolibrary.org/obo/UO_0000027\tsample1\tliver\tUBERON\thttp://purl.obolibrary.org/obo/UBERON_0002107\t450.5\tmilligram\tUO\thttp://purl.obolibrary.org/obo/UO_0000022"""
self.assertIn(expected, actual)
Expand Down
6 changes: 3 additions & 3 deletions tests/validators/test_validate_test_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ class TestIsaJsonCreateTestData(unittest.TestCase):

def setUp(self):
self._reporting_level = logging.ERROR
self.v2_create_schemas_path = pathlib.PurePosixPath(
self.v2_create_schemas_path = pathlib.Path(
pathlib.Path(__file__).parents[0], '..', '..', 'isatools', 'resources', 'schemas',
'isa_model_version_2_0_schemas', 'create')

Expand All @@ -315,7 +315,7 @@ def test_validate_testdata_sampleassayplan_json(self):
with open(os.path.join(self.v2_create_schemas_path,
'sample_assay_plan_schema.json')) as fp:
sample_assay_plan_schema = json.load(fp)
res_path = pathlib.PurePosixPath("file://", self.v2_create_schemas_path,
res_path = pathlib.Path("file://", self.v2_create_schemas_path,
'sample_assay_plan_schema.json').as_uri()
resolver = RefResolver(res_path, sample_assay_plan_schema)
validator = Draft4Validator(sample_assay_plan_schema,
Expand All @@ -342,7 +342,7 @@ def test_validate_testdata_treatment_sequence_json(self):
with open(os.path.join(self.v2_create_schemas_path,
'treatment_sequence_schema.json')) as fp:
treatment_sequence_schema = json.load(fp)
res_path = pathlib.PurePosixPath("file://", self.v2_create_schemas_path,
res_path = pathlib.Path("file://", self.v2_create_schemas_path,
'treatment_sequence_schema.json').as_uri()
resolver = RefResolver(res_path, treatment_sequence_schema)
validator = Draft4Validator(treatment_sequence_schema,
Expand Down

0 comments on commit 6d30dc2

Please sign in to comment.