Example #1
0
 def test_declarations_from_comment_with_a_multiline_annotation(self):
     self.assertEquals(["MyAnnotation(Value=\"hello\")"], annotations.declarations(["@custom:MyAnnotation(", "Value=\"hello\")"]))
Example #2
0
 def test_declarations_from_comment_with_an_annotation(self):
     self.assertEquals(["MyAnnotation(Value=1)"], annotations.declarations(["@custom:MyAnnotation(Value=1)"]))
Example #3
0
 def test_declarations_from_comment_with_text_and_two_annotations(self):
     self.assertEquals(["MyAnnotation()", "HisAnnotation()"], annotations.declarations(["Here starts my comment", "@custom:MyAnnotation()", "@custom:HisAnnotation()"]))
Example #4
0
 def test_declarations_from_comment_with_text(self):
     self.assertEquals([], annotations.declarations(["Comment without annotation"]))