def test_success(self): resource_conf = { "name": "test-project", "logging_info": [{ "broker_logs": [{ "cloudwatch_logs": [{ "enabled": True, }], }], }], } scan_result = check.scan_resource_conf(conf=resource_conf) self.assertEqual(CheckResult.PASSED, scan_result)
def test_failure(self): resource_conf = { "name": "test-project", "logging_info": [{ "broker_logs": [{ "cloudwatch_logs": [{ "enabled": False, }], }], }], } scan_result = check.scan_resource_conf(conf=resource_conf) self.assertEqual(CheckResult.FAILED, scan_result)
def test_failure_none(self): resource_conf = { "name": "test-project", } scan_result = check.scan_resource_conf(conf=resource_conf) self.assertEqual(CheckResult.FAILED, scan_result)