Skip to content

Commit bbaeb05

Browse files
committed
WIP
1 parent c612542 commit bbaeb05

File tree

3 files changed

+22
-13
lines changed

3 files changed

+22
-13
lines changed

.pre-commit-config.yaml

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -61,19 +61,23 @@ repos:
6161
- --no-warn-unused-ignores # https://github.com/python/mypy/issues/8823, https://github.com/python/mypy/issues/8990
6262
- repo: local
6363
hooks:
64-
# - id: pylint-local
65-
# name: pylint-local
66-
# description: Run pylint in the local virtualenv
67-
# entry: pylint "setup.py" "src/" "python/" "tests/"
68-
# language: system
69-
# # ignore all files, run on hard-coded modules instead
70-
# pass_filenames: false
71-
# always_run: true
64+
- id: pylint-local
65+
name: pylint-local
66+
description: Run pylint in the local virtualenv
67+
entry: pylint "setup.py" "src/" "python/" "tests/"
68+
language: system
69+
# ignore all files, run on hard-coded modules instead
70+
pass_filenames: false
71+
always_run: true
7272
- id: pytest-local
7373
name: pytest-local
7474
description: Run pytest in the local virtualenv
7575
entry: >
7676
pytest
77+
--cov-report=term
78+
--cov-report=html
79+
--cov="rpdk.python"
80+
--cov="cloudformation_cli_python_lib"
7781
--durations=5
7882
"tests/"
7983
language: system

tests/lib/hook_test.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -485,6 +485,10 @@ def test_test_entrypoint_success():
485485
(OperationStatus.IN_PROGRESS, HookStatus.IN_PROGRESS),
486486
(OperationStatus.SUCCESS, HookStatus.SUCCESS),
487487
(OperationStatus.FAILED, HookStatus.FAILED),
488+
(
489+
OperationStatus.CHANGE_SET_SUCCESS_SKIP_STACK_HOOK,
490+
HookStatus.CHANGE_SET_SUCCESS_SKIP_STACK_HOOK,
491+
),
488492
],
489493
)
490494
def test_get_hook_status(operation_status, hook_status):

tests/lib/interface_test.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -185,8 +185,9 @@ def test_hook_progress_event_serialize_to_response_with_error_code(message):
185185
}
186186

187187

188-
# add this test back when
189-
# def test_operation_status_enum_matches_sdk(client):
190-
# sdk = set(client.meta.service_model.shape_for("OperationStatus").enum)
191-
# enum = set(OperationStatus.__members__)
192-
# assert enum == sdk
188+
def test_operation_status_enum_matches_sdk(client):
189+
sdk = set(client.meta.service_model.shape_for("OperationStatus").enum)
190+
enum = set(OperationStatus.__members__)
191+
# CHANGE_SET_SUCCESS_SKIP_STACK_HOOK is a status specific to Hooks
192+
enum.remove("CHANGE_SET_SUCCESS_SKIP_STACK_HOOK")
193+
assert enum == sdk

0 commit comments

Comments
 (0)