def test_annotation_transformation(): ext = AnnotationExtension() ctx = Context() result = ext.transform(ctx, endpoint, 1134) assert result == ('int', 1134)
def test_annotation_transformation(): ext = AnnotationExtension() ctx = Context() result = ext.transform(ctx, endpoint, 1134) assert result == ('int', 1134)
def test_annotation_bare(): ext = AnnotationExtension() ctx = Context() args = [] kwargs = {'a': '27', 'b': '42'} ext.mutate(ctx, bare_endpoint, args, kwargs) assert kwargs == {'a': '27', 'b': '42'} assert ext.transform(ctx, bare_endpoint, None) is None
def test_annotation_bare(): ext = AnnotationExtension() ctx = Context() args = [] kwargs = {'a': '27', 'b': '42'} ext.mutate(ctx, bare_endpoint, args, kwargs) assert kwargs == {'a': '27', 'b': '42'} assert ext.transform(ctx, bare_endpoint, None) is None