Skip to content

Commit 5d4a6e4

Browse files
committed
Resolve remaining issues
1 parent 00aed51 commit 5d4a6e4

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

.github/workflows/create-release-tag.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,7 @@ jobs:
2929
run: pip install semver
3030

3131
- name: Set SPEC_VERSION env var
32-
run: echo ::set-env name=SPEC_VERSION::$(python utilities/scripts/calculate_version.py)
33-
env:
34-
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
32+
run: echo "SPEC_VERSION::$(python utilities/scripts/calculate_version.py)" >> $GITHUB_ENV
3533

3634
- name: Create release (master only)
3735
id: create-release

lambdas/shared/tests/test_common/test_errors.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,16 @@ def test_errors_unhandled_response_error(self):
128128
self.assertEqual(issue.get("code"), errors.Code.exception)
129129
self.assertEqual(issue.get("diagnostics"), f"{test_message}\n{test_response}")
130130

131+
def test_errors_api_validation_error(self):
132+
"""Test base ApiValidationError class cannot be used"""
133+
with self.assertRaises(errors.ApiValidationError) as initial_error:
134+
raise errors.ApiValidationError()
135+
136+
with self.assertRaises(NotImplementedError) as not_implemented_error:
137+
initial_error.exception.to_operation_outcome()
138+
139+
self.assertEqual(str(not_implemented_error.exception), "Improper usage: base class")
140+
131141
def test_errors_custom_validation_error(self):
132142
"""Test correct operation of CustomValidationError"""
133143
test_message = "test_message"

0 commit comments

Comments
 (0)