Exemplo n.º 1
0
 def test_selective_eval_evaluates(self):
     """
     Given string representing a function, evaluate
     """
     s = "{'Ref': 'AWS::StackId'}"
     expected = dict(Ref="AWS::StackId")
     self.assertEquals(expected, _selective_eval(s))
Exemplo n.º 2
0
 def test_selective_eval_evaluates(self):
     """
     Given string representing a function, evaluate
     """
     s = "{'Ref': 'AWS::StackId'}"
     expected = dict(Ref='AWS::StackId')
     self.assertEquals(expected, _selective_eval(s))
Exemplo n.º 3
0
 def test_selective_eval_noeval(self):
     """
     Assert selective eval returns s if s is not a function 'atom'
     """
     s = "this is embedded {'Ref': 'AWS::StackId'} in string"
     self.assertEquals(s, _selective_eval(s))
Exemplo n.º 4
0
 def test_selective_eval_noeval(self):
     """
     Assert selective eval returns s if s is not a function 'atom'
     """
     s = "this is embedded {'Ref': 'AWS::StackId'} in string"
     self.assertEquals(s, _selective_eval(s))