Skip to content

Commit

Permalink
Fix an issue where "target" was on the excluded list
Browse files Browse the repository at this point in the history
  • Loading branch information
hsolbrig committed Dec 3, 2020
1 parent 8cedfa7 commit 26f3d11
Show file tree
Hide file tree
Showing 2 changed files with 74 additions and 1 deletion.
73 changes: 73 additions & 0 deletions tests/test_utils/object/observation_example_haplotype1.ttl
@@ -0,0 +1,73 @@
<http://hl7.org/fhir/MolecularSequence/example-pgx-1> rdf:type fhir:MolecularSequence .
<http://hl7.org/fhir/MolecularSequence/example-pgx-2> rdf:type fhir:MolecularSequence .
<http://hl7.org/fhir/Observation/example-haplotype1> fhir:DomainResource.extension _:b1 .
<http://hl7.org/fhir/Observation/example-haplotype1> fhir:DomainResource.text _:b2 .
<http://hl7.org/fhir/Observation/example-haplotype1> fhir:Observation.code _:b3 .
<http://hl7.org/fhir/Observation/example-haplotype1> fhir:Observation.derivedFrom _:b4 .
<http://hl7.org/fhir/Observation/example-haplotype1> fhir:Observation.derivedFrom _:b5 .
<http://hl7.org/fhir/Observation/example-haplotype1> fhir:Observation.issued _:b6 .
<http://hl7.org/fhir/Observation/example-haplotype1> fhir:Observation.specimen _:b7 .
<http://hl7.org/fhir/Observation/example-haplotype1> fhir:Observation.status _:b8 .
<http://hl7.org/fhir/Observation/example-haplotype1> fhir:Observation.subject _:b9 .
<http://hl7.org/fhir/Observation/example-haplotype1> fhir:Observation.valueCodeableConcept _:b10 .
<http://hl7.org/fhir/Observation/example-haplotype1> fhir:Resource.id _:b11 .
<http://hl7.org/fhir/Observation/example-haplotype1> fhir:nodeRole fhir:treeRoot .
<http://hl7.org/fhir/Observation/example-haplotype1> rdf:type fhir:Observation .
<http://hl7.org/fhir/Observation/example-haplotype1.ttl> rdf:type owl:Ontology .
<http://hl7.org/fhir/Observation/example-haplotype1.ttl> owl:imports fhir:fhir.ttl .
<http://hl7.org/fhir/Observation/example-haplotype1.ttl> owl:versionIRI <http://build.fhir.org/Observation/example-haplotype1.ttl> .
<http://hl7.org/fhir/Patient/727127> rdf:type fhir:Patient .
<http://hl7.org/fhir/Specimen/genetics-example1-somatic> rdf:type fhir:Specimen .
_:b11 fhir:value "example-haplotype1" .
_:b2 fhir:Narrative.div "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Generated Narrative with Details</b></p><p><b>id</b>: example-haplotype1</p><p><b>status</b>: unknown</p><p><b>code</b>: Genetic analysis master panel-- This is the parent OBR for the panel holding all of the associated observations that can be reported with a molecular genetics analysis result. <span>(Details : {LOINC code '55233-1' = 'Genetic analysis master panel - Blood or Tissue by Molecular genetics method', given as 'Genetic analysis master panel-- This is the parent OBR for the panel holding all of the associated observations that can be reported with a molecular genetics analysis result.'})</span></p><p><b>subject</b>: <a>J*********** C***********</a></p><p><b>issued</b>: Apr 3, 2013 3:30:10 PM</p><p><b>value</b>: *35B <span>(Details : {http://pharmakb.org code 'PA165971587' = 'PA165971587', given as '*35B'})</span></p><p><b>specimen</b>: <a>Molecular Specimen ID: MLD45-Z4-1234</a></p><p><b>derivedFrom</b>: </p><ul><li><a>MolecularSequence/example-pgx-1</a></li><li><a>MolecularSequence/example-pgx-2</a></li></ul></div>" .
_:b2 fhir:Narrative.status _:b12 .
_:b12 fhir:value "generated" .
_:b1 fhir:Extension.url _:b13 .
_:b1 fhir:Extension.valueCodeableConcept _:b14 .
_:b1 fhir:index "0"^^xsd:integer .
_:b13 fhir:value "http://hl7.org/fhir/StructureDefinition/observation-geneticsGene" .
_:b14 fhir:CodeableConcept.coding _:b15 .
_:b15 fhir:Coding.code _:b16 .
_:b15 fhir:Coding.display _:b17 .
_:b15 fhir:Coding.system _:b18 .
_:b15 fhir:index "0"^^xsd:integer .
_:b18 fhir:value "http://www.genenames.org" .
_:b16 fhir:value "2625" .
_:b17 fhir:value "CYP2D6" .
_:b8 fhir:value "unknown" .
_:b3 fhir:CodeableConcept.coding _:b19 .
_:b19 fhir:Coding.code _:b20 .
_:b19 fhir:Coding.display _:b21 .
_:b19 fhir:Coding.system _:b22 .
_:b19 fhir:index "0"^^xsd:integer .
_:b19 rdf:type loinc:55233-1 .
_:b22 fhir:value "http://loinc.org" .
_:b20 fhir:value "55233-1" .
_:b21 fhir:value "Genetic analysis master panel-- This is the parent OBR for the panel holding all of the associated observations that can be reported with a molecular genetics analysis result." .
_:b9 fhir:Reference.display _:b23 .
_:b9 fhir:Reference.reference _:b24 .
_:b9 fhir:link <http://hl7.org/fhir/Patient/727127> .
_:b24 fhir:value "Patient/727127" .
_:b23 fhir:value "J*********** C***********" .
_:b6 fhir:value "2013-04-03T15:30:10+01:00"^^xsd:dateTime .
_:b10 fhir:CodeableConcept.coding _:b25 .
_:b25 fhir:Coding.code _:b26 .
_:b25 fhir:Coding.display _:b27 .
_:b25 fhir:Coding.system _:b28 .
_:b25 fhir:index "0"^^xsd:integer .
_:b28 fhir:value "http://pharmakb.org" .
_:b26 fhir:value "PA165971587" .
_:b27 fhir:value "*35B" .
_:b7 fhir:Reference.display _:b29 .
_:b7 fhir:Reference.reference _:b30 .
_:b7 fhir:link <http://hl7.org/fhir/Specimen/genetics-example1-somatic> .
_:b30 fhir:value "Specimen/genetics-example1-somatic" .
_:b29 fhir:value "Molecular Specimen ID: MLD45-Z4-1234" .
_:b4 fhir:Reference.reference _:b31 .
_:b4 fhir:index "0"^^xsd:integer .
_:b4 fhir:link <http://hl7.org/fhir/MolecularSequence/example-pgx-1> .
_:b31 fhir:value "MolecularSequence/example-pgx-1" .
_:b5 fhir:Reference.reference _:b32 .
_:b5 fhir:index "1"^^xsd:integer .
_:b5 fhir:link <http://hl7.org/fhir/MolecularSequence/example-pgx-2> .
_:b32 fhir:value "MolecularSequence/example-pgx-2" .
2 changes: 1 addition & 1 deletion tests/test_utils/test_n3_mapper.py
Expand Up @@ -9,7 +9,7 @@
class N3MapperUnitTest(unittest.TestCase):
def test_basics(self):
source_dir = os.path.join(os.path.abspath(os.path.dirname(__file__)), 'source')
target_dir = os.path.join(os.path.abspath(os.path.dirname(__file__)), 'target')
target_dir = os.path.join(os.path.abspath(os.path.dirname(__file__)), 'object')
new_files = False

os.makedirs(target_dir, exist_ok=True)
Expand Down

0 comments on commit 26f3d11

Please sign in to comment.