File tree Expand file tree Collapse file tree 3 files changed +39
-2
lines changed
Expand file tree Collapse file tree 3 files changed +39
-2
lines changed Original file line number Diff line number Diff line change @@ -83,3 +83,38 @@ smoketest-prod:
8383test-prod :
8484 $(PROD_CMD ) \
8585 --junitxml=test-report.xml \
86+
87+ # Run schema validation check
88+
89+ schema-consent :
90+
91+ @for file in specification/examples/responses/GET_Consent/*.yaml; do \
92+ if [ "$$file" = "specification/examples/responses/GET_Consent/filtered-relationships-status-active-include-details.yaml" ]; then \
93+ continue; \
94+ fi; \
95+ if [ "$$file" = "specification/examples/responses/GET_Consent/multiple-relationships-include-patient.yaml" ]; then \
96+ continue; \
97+ fi; \
98+ if [ "$$file" = "specification/examples/responses/GET_Consent/multiple-relationships-include-performer-patient.yaml" ]; then \
99+ continue; \
100+ fi; \
101+ if [ "$$file" = "specification/examples/responses/GET_Consent/multiple-relationships-include-performer.yaml" ]; then \
102+ continue; \
103+ fi; \
104+ if [ "$$file" = "specification/examples/responses/GET_Consent/single-consenting-adult-relationship-include-performer-patient.yaml" ]; then \
105+ continue; \
106+ fi; \
107+ if [ "$$file" = "specification/examples/responses/GET_Consent/single-mother-child-relationship-include-performer-patient.yaml" ]; then \
108+ continue; \
109+ fi; \
110+ echo "Processing $$file"; \
111+ poetry run python scripts/validate_schema.py consent "$$(realpath $$file)"; \
112+ done
113+
114+
115+ # cd scripts
116+
117+ # $(foreach file, $(FILES), poetry run python scripts/validate_schema.py consent $(file)";)
118+ #
119+ # @for file in ../specification/examples/responses/GET_Consent/*.yaml; do echo $$file; done
120+ # @for file in ../specification/examples/responses/GET_Consent/*.yaml; do poetry run python scripts/validate_schema.py consent $$file; done
Original file line number Diff line number Diff line change 1111import datetime
1212import sys
1313
14+ EXAMPLES_PATH = "../"
1415SCHEMA_FILE_PATH = "../specification/validated-relationships-service-api.yaml"
1516SCHEMA_FILE = path .join (path .dirname (path .realpath (__file__ )), SCHEMA_FILE_PATH )
1617openapi_schema = {}
1920def main (openapi_schema : dict ):
2021 """Main entrypoint"""
2122 args = sys .argv
23+ print ("args:" )
24+ print (args )
25+ print ("******" )
2226 if len (args ) != 3 :
2327 print ("Require schema reference and file to validate" )
2428 exit ()
Original file line number Diff line number Diff line change @@ -1594,8 +1594,6 @@ components:
15941594 scope :
15951595 $ref : ' #/components/schemas/CodeableConcept'
15961596 description : " The scope of the consent, bound to http://terminology.hl7.org/CodeSystem/consentscope"
1597- enum :
1598- - patient-privacy
15991597 category :
16001598 type : array
16011599 items :
You can’t perform that action at this time.
0 commit comments