From dbfeee6925e2c43f5dd6878023ca47e2132d30a9 Mon Sep 17 00:00:00 2001 From: Edward Rousseau Date: Thu, 21 Jun 2018 15:15:38 +1000 Subject: [PATCH 1/2] Fixed validator for task_type to match reality - AWS CF documentation seems to be missing an S --- troposphere/validators.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/troposphere/validators.py b/troposphere/validators.py index b66df138e..3a56b7c2d 100644 --- a/troposphere/validators.py +++ b/troposphere/validators.py @@ -266,7 +266,7 @@ def notification_event(events): def task_type(task): - valid_tasks = ['RUN_COMMAND', 'AUTOMATION', 'LAMBDA', 'STEP_FUNCTION'] + valid_tasks = ['RUN_COMMAND', 'AUTOMATION', 'LAMBDA', 'STEP_FUNCTIONS'] if task not in valid_tasks: raise ValueError( 'TaskType must be one of: "%s"' % ( From 8a485745e98b839f6684b989fdeedd00a78eac17 Mon Sep 17 00:00:00 2001 From: Edward Rousseau Date: Thu, 21 Jun 2018 15:24:24 +1000 Subject: [PATCH 2/2] Update test to match change to validators --- tests/test_validators.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/test_validators.py b/tests/test_validators.py index 4463e9132..6798564f0 100644 --- a/tests/test_validators.py +++ b/tests/test_validators.py @@ -202,7 +202,7 @@ def test_operating_system(self): operating_system(s) def test_task_type(self): - for s in ['RUN_COMMAND', 'AUTOMATION', 'LAMBDA', 'STEP_FUNCTION']: + for s in ['RUN_COMMAND', 'AUTOMATION', 'LAMBDA', 'STEP_FUNCTIONS']: task_type(s) for s in ['', 'foo', 'a', 'l@mbda', 'STEPFUNCTION']: with self.assertRaises(ValueError):