Skip to content

Commit af62306

Browse files
committed
NPA-5086 Move Files and Validate Errors
1 parent 5c0bfb7 commit af62306

File tree

5 files changed

+15
-3
lines changed

5 files changed

+15
-3
lines changed

.github/workflows/openapi-validate.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,10 @@ jobs:
4141
make_target: "schema-get-questionnaire",
4242
},
4343
{ name: "Errors", make_target: "schema-errors" },
44+
{
45+
name: "GET Consent/{ID}",
46+
make_target: "schema-get-consent-by-id",
47+
},
4448
]
4549
steps:
4650
- name: Checkout repository

Makefile

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,7 @@ RESET := \033[0m
9595

9696
schema-all:
9797
make schema-get-consent \
98+
schema-get-consent-by-id \
9899
schema-post-consent \
99100
schema-patch-consent \
100101
schema-related-person \
@@ -108,6 +109,13 @@ schema-get-consent:
108109
echo -e "$(GREEN)Success!$(RESET)"; \
109110
done
110111

112+
schema-get-consent-by-id:
113+
@for file in specification/examples/responses/GET_Consent/ID/*.yaml; do \
114+
echo "Processing $$file"; \
115+
poetry run python scripts/validate_schema.py consent "$$(realpath $$file)"; \
116+
echo -e "$(GREEN)Success!$(RESET)"; \
117+
done
118+
111119
schema-post-consent:
112120
@for file in specification/examples/responses/POST_Consent/*.yaml; do \
113121
echo "Processing $$file"; \
@@ -148,4 +156,4 @@ schema-get-questionnaire:
148156
echo "Processing $$file"; \
149157
poetry run python scripts/validate_schema.py questionnaireresponse "$$(realpath $$file)"; \
150158
echo -e "$(GREEN)Success!$(RESET)"; \
151-
done
159+
done

specification/examples/responses/GET_CONSENT_ID/errors/invalid-id.yaml renamed to specification/examples/responses/GET_Consent/ID/invalid-id.yaml

File renamed without changes.

specification/examples/responses/GET_CONSENT_ID/errors/missing-id.yaml renamed to specification/examples/responses/GET_Consent/ID/missing-id.yaml

File renamed without changes.

specification/validated-relationships-service-api.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -796,9 +796,9 @@ paths:
796796
InvalidatedResourceError:
797797
$ref: "./examples/responses/errors/invalidated-resource.yaml#/InvalidatedResourceError"
798798
MissingIdError:
799-
$ref: "./examples/responses/GET_CONSENT_ID/errors/missing-id.yaml#/ConsentMissingIDError"
799+
$ref: "./examples/responses/GET_Consent/ID/errors/missing-id.yaml#/ConsentMissingIDError"
800800
InvalidIdError:
801-
$ref: "./examples/responses/GET_CONSENT_ID/errors/invalid-id.yaml#/ConsentInvalidIDError"
801+
$ref: "./examples/responses/GET_Consent/ID/errors/invalid-id.yaml#/ConsentInvalidIDError"
802802
"5XX":
803803
description: |
804804
Errors will be returned for the first error encountered in the request. An error occurred as follows:

0 commit comments

Comments
 (0)