Ejemplo n.º 1
0
def test_uncomment_indentation_before_after():
    prefix = CommentPrefix('#')
    got = prefix.uncomment(['#foo', ' # bar'])
    assert got == ['foo', '  bar']
Ejemplo n.º 2
0
def test_uncomment_many_levels():
    prefix = CommentPrefix('#')
    got = prefix.uncomment(['##foo', '###bar'])
    assert got == ['foo', '#bar']
Ejemplo n.º 3
0
def test_uncomment_preserve_partial():
    prefix = CommentPrefix('#')
    got = prefix.uncomment(['foo', '#bar'])
    assert got == ['foo', '#bar']
Ejemplo n.º 4
0
def test_uncomment():
    prefix = CommentPrefix('#')
    got = prefix.uncomment(['#foo', '#bar'])
    assert got == ['foo', 'bar']
Ejemplo n.º 5
0
def test_uncomment_empty():
    prefix = CommentPrefix('#')
    got = prefix.uncomment([])
    assert got == []