#NEWLINE# def test_resource_with_properties( self ) : #NEWLINE# #INDENT# properties_dict = { #NEWLINE# #INDENT# 'Key1' : 'Value1' , #NEWLINE# 'Key2' : 'Value2' , #NEWLINE# #UNINDENT# } #NEWLINE# properties = core . Properties ( properties_dict ) #NEWLINE# res = core . Resource ( 'TestResource' , 'AWS::Resource::Test' , properties ) #NEWLINE# cft = core . CloudFormationTemplate ( ) #NEWLINE# cft . resources . test = res #NEWLINE# expected_out = dedent ( '        {\n          "Type": "AWS::Resource::Test",\n          "Properties": {\n            "Key2": "Value2",\n            "Key1": "Value1"\n          }\n        }' ) #NEWLINE# self . assertEqual ( unicode ( cft . resources . test ) , expected_out )