{"name": "bundle-pull-organization-id-repeated", "comment": "Two Organizations of a pull sharing one id are no record and a finding each, and a lab result whose performer names that id is attributed to none.", "input": {"file": "fixtures/in/bundle-pull-organization-id-repeated.json", "link": "https://github.com/the-cascade-protocol/cascade-bridge-adapter-fhir-r4/blob/15621eef1b6e4578c254871490838e45939a8487/fixtures/in/bundle-pull-organization-id-repeated.json", "text": "{\n  \"resourceType\": \"Bundle\",\n  \"type\": \"collection\",\n  \"entry\": [\n    {\n      \"fullUrl\": \"https://fhir.example.org/r4/Organization/org-twice\",\n      \"resource\": {\n        \"resourceType\": \"Organization\",\n        \"id\": \"org-twice\",\n        \"name\": \"Example Clinic\"\n      }\n    },\n    {\n      \"fullUrl\": \"https://fhir.example.org/r4/Organization/org-twice\",\n      \"resource\": {\n        \"resourceType\": \"Organization\",\n        \"id\": \"org-twice\",\n        \"name\": \"Example Clinic North\"\n      }\n    },\n    {\n      \"fullUrl\": \"https://fhir.example.org/r4/Observation/obs-potassium-5\",\n      \"resource\": {\n        \"resourceType\": \"Observation\",\n        \"id\": \"obs-potassium-5\",\n        \"status\": \"final\",\n        \"category\": [\n          {\n            \"coding\": [\n              {\n                \"system\": \"http://terminology.hl7.org/CodeSystem/observation-category\",\n                \"code\": \"laboratory\"\n              }\n            ]\n          }\n        ],\n        \"code\": {\n          \"coding\": [\n            {\n              \"system\": \"http://loinc.org\",\n              \"code\": \"2823-3\",\n              \"display\": \"Potassium [Moles/volume] in Serum or Plasma\"\n            }\n          ],\n          \"text\": \"Potassium\"\n        },\n        \"subject\": {\n          \"reference\": \"Patient/pat-1\"\n        },\n        \"effectiveDateTime\": \"2026-09-29T07:30:00Z\",\n        \"performer\": [\n          {\n            \"reference\": \"Organization/org-twice\"\n          }\n        ],\n        \"valueQuantity\": {\n          \"value\": 4.1,\n          \"unit\": \"mmol/L\",\n          \"system\": \"http://unitsofmeasure.org\",\n          \"code\": \"mmol/L\"\n        }\n      }\n    }\n  ]\n}\n"}, "expectedGraph": {"file": "fixtures/expected/bundle-pull-organization-id-repeated.ttl", "link": "https://github.com/the-cascade-protocol/cascade-bridge-adapter-fhir-r4/blob/15621eef1b6e4578c254871490838e45939a8487/fixtures/expected/bundle-pull-organization-id-repeated.ttl", "text": "@prefix bridge: <https://ns.cascadeprotocol.org/bridge/v1-draft#> .\n@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .\n@prefix cascade: <https://ns.cascadeprotocol.org/cascade#> .\n@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .\n@prefix prov: <http://www.w3.org/ns/prov#> .\n@prefix dct: <http://purl.org/dc/terms/> .\n@prefix dcterms: <http://purl.org/dc/terms/> .\n@prefix oa: <http://www.w3.org/ns/oa#> .\n@prefix pav: <http://purl.org/pav/> .\n<ni:///sha-256;iaH_XU9xgcYWxdq4_TBvgX1GsGlR8tndbQqNcmAjN9E> cascade:resultQuantity <ni:///sha-256;iaH_XU9xgcYWxdq4_TBvgX1GsGlR8tndbQqNcmAjN9E#value> .\n<ni:///sha-256;iaH_XU9xgcYWxdq4_TBvgX1GsGlR8tndbQqNcmAjN9E#value> cascade:decimalValue 4.1 ;\n\tcascade:writtenValue \"4.1\" ;\n\tcascade:ucumUnit \"mmol/L\" ;\n\tcascade:unitText \"mmol/L\" .\n<ni:///sha-256;iaH_XU9xgcYWxdq4_TBvgX1GsGlR8tndbQqNcmAjN9E> cascade:testName \"Potassium\" ;\n\tcascade:testCode <http://loinc.org/rdf/2823-3> ;\n\tcascade:resultValueKind cascade:QuantityResultValue ;\n\tcascade:resultClinicallyRelevantTime \"2026-09-29T07:30:00Z\"^^xsd:dateTime ;\n\tcascade:workflowStatus \"final\" .\n<urn:uuid:0a5acedf-873a-8f5d-8cb1-6dae23adcea2> a cascade:LaboratoryTestResult ;\n\tcascade:sourceUrl <https://fhir.example.org/r4/Observation/obs-potassium-5> ;\n\tcascade:sourceRecordId \"obs-potassium-5\" .\n<ni:///sha-256;iaH_XU9xgcYWxdq4_TBvgX1GsGlR8tndbQqNcmAjN9E> prov:specializationOf <urn:uuid:0a5acedf-873a-8f5d-8cb1-6dae23adcea2> ;\n\tcascade:patient <urn:uuid:dccb6776-d640-88e5-a7b3-7e2e1b860abe> .\n_:bc6698b4bedced74932295450e92ae9a bridge:arrivedAs <ni:///sha-256;iaH_XU9xgcYWxdq4_TBvgX1GsGlR8tndbQqNcmAjN9E> ;\n\toa:hasSelector _:fe0e272d78a08641095e363ccdc3a677 ;\n\toa:hasSource <ni:///sha-256;jXAsqZC4v1xF953J50wbTv9NCBkwttwP7rJW-uwj5iI> ;\n\tprov:wasDerivedFrom <ni:///sha-256;jXAsqZC4v1xF953J50wbTv9NCBkwttwP7rJW-uwj5iI> ;\n\tprov:wasGeneratedBy _:ab3c7d11d90474b17d6d9a9c311ecea0 .\n_:fe0e272d78a08641095e363ccdc3a677 a oa:FragmentSelector ;\n\tdct:conformsTo <https://www.rfc-editor.org/rfc/rfc6901> ;\n\trdf:value \"/entry/2\" .\n<ni:///sha-256;jXAsqZC4v1xF953J50wbTv9NCBkwttwP7rJW-uwj5iI> cascade:serverBaseUrl \"https://fhir.example.org/r4\" ;\n\tpav:retrievedOn \"2026-10-16T09:00:00Z\"^^xsd:dateTime ;\n\tcascade:sourceFormatVersion \"4.0.1\" .\n_:ab3c7d11d90474b17d6d9a9c311ecea0 <http://www.w3.org/2000/01/rdf-schema#label> \"Example hospital pull\" ;\n\tprov:startedAtTime \"2026-10-16T09:00:04Z\"^^xsd:dateTime .\n<ni:///sha-256;jXAsqZC4v1xF953J50wbTv9NCBkwttwP7rJW-uwj5iI> a prov:Entity .\n_:ab3c7d11d90474b17d6d9a9c311ecea0 a prov:Activity ;\n\tprov:used <ni:///sha-256;jXAsqZC4v1xF953J50wbTv9NCBkwttwP7rJW-uwj5iI> ;\n\tprov:qualifiedAssociation _:1c93f06ff425a830385496aa3162ff54 .\n_:1c93f06ff425a830385496aa3162ff54 prov:hadPlan _:d980e416161525e59793b0f9e2a1f7c8 .\n_:d980e416161525e59793b0f9e2a1f7c8 a prov:Plan ;\n\t<http://www.w3.org/2000/01/rdf-schema#label> \"fhir-r4\" ;\n\tpav:version \"0.1.0\" .\n_:1c93f06ff425a830385496aa3162ff54 prov:agent _:c4ffc9bc6388cf1dd28f948809e5862a .\n_:c4ffc9bc6388cf1dd28f948809e5862a a prov:SoftwareAgent ;\n\t<http://www.w3.org/2000/01/rdf-schema#label> \"Cascade Bridge for Rust\" ;\n\tpav:version \"0.1.0\" .\n"}, "expectedFindings": {"file": "fixtures/findings/bundle-pull-organization-id-repeated.ttl", "link": "https://github.com/the-cascade-protocol/cascade-bridge-adapter-fhir-r4/blob/15621eef1b6e4578c254871490838e45939a8487/fixtures/findings/bundle-pull-organization-id-repeated.ttl", "text": "@prefix fhirr4: <https://ns.cascadeprotocol.org/adapter/fhir-r4/v1-draft#> .\n@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .\n@prefix sh: <http://www.w3.org/ns/shacl#> .\n@prefix oa: <http://www.w3.org/ns/oa#> .\n_:f130b551269d345634b12a2eefce981b a oa:FragmentSelector ;\n\t<http://purl.org/dc/terms/conformsTo> <https://www.rfc-editor.org/rfc/rfc6901> ;\n\trdf:value \"/entry/0\" .\n_:f8d31b148c8ecd6cb15c13f3ec413139 oa:hasSource <../in/bundle-pull-organization-id-repeated.json> .\n_:f130b551269d345634b12a2eefce981b oa:refinedBy _:daaa679f3e46ca55aed91d8d28fda47d .\n_:daaa679f3e46ca55aed91d8d28fda47d a oa:FragmentSelector ;\n\t<http://purl.org/dc/terms/conformsTo> <https://www.rfc-editor.org/rfc/rfc6901> ;\n\trdf:value \"/resource/id\" .\n_:f8d31b148c8ecd6cb15c13f3ec413139 oa:hasSelector _:f130b551269d345634b12a2eefce981b .\n_:a7590c984d96edddc55585d669f8ec06 oa:hasTarget _:f8d31b148c8ecd6cb15c13f3ec413139 ;\n\tsh:resultSeverity sh:Info ;\n\ta oa:Annotation ;\n\toa:hasBody fhirr4:resourceIdRepeated ;\n\toa:motivatedBy oa:classifying ;\n\tsh:value \"org-twice\" .\n_:a6ca616b05f55ee44173444387b089bb a oa:FragmentSelector ;\n\t<http://purl.org/dc/terms/conformsTo> <https://www.rfc-editor.org/rfc/rfc6901> ;\n\trdf:value \"/entry/1\" .\n_:a29886ab59ef2c2974a349da11db50d0 oa:hasSource <../in/bundle-pull-organization-id-repeated.json> .\n_:a6ca616b05f55ee44173444387b089bb oa:refinedBy _:f9c0267b3e3f90f1fa96fe17e4acf252 .\n_:f9c0267b3e3f90f1fa96fe17e4acf252 a oa:FragmentSelector ;\n\t<http://purl.org/dc/terms/conformsTo> <https://www.rfc-editor.org/rfc/rfc6901> ;\n\trdf:value \"/resource/id\" .\n_:a29886ab59ef2c2974a349da11db50d0 oa:hasSelector _:a6ca616b05f55ee44173444387b089bb .\n_:c26686d3699178db2c02f603c0ee2f1b oa:hasTarget _:a29886ab59ef2c2974a349da11db50d0 ;\n\tsh:resultSeverity sh:Info ;\n\ta oa:Annotation ;\n\toa:hasBody fhirr4:resourceIdRepeated ;\n\toa:motivatedBy oa:classifying ;\n\tsh:value \"org-twice\" .\n", "empty": false}}