Beispiel #1
0
def test_Wrt_preprocess():
    Wrt.preprocess(x) == ["x"]
    Wrt.preprocess("x,y") == ["x", "y"]
    Wrt.preprocess("x y") == ["x", "y"]
    Wrt.preprocess("x, y") == ["x", "y"]
    Wrt.preprocess([x, y]) == ["x", "y"]

    raises(OptionError, "Wrt.preprocess(0)")
Beispiel #2
0
def test_Wrt_preprocess():
    Wrt.preprocess(x) == ['x']
    Wrt.preprocess('x,y') == ['x', 'y']
    Wrt.preprocess('x y') == ['x', 'y']
    Wrt.preprocess('x, y') == ['x', 'y']
    Wrt.preprocess([x, y]) == ['x', 'y']

    raises(OptionError, "Wrt.preprocess(0)")
Beispiel #3
0
def test_Wrt_preprocess():
    assert Wrt.preprocess(x) == ['x']
    assert Wrt.preprocess('') == []
    assert Wrt.preprocess(' ') == []
    assert Wrt.preprocess('x,y') == ['x', 'y']
    assert Wrt.preprocess('x y') == ['x', 'y']
    assert Wrt.preprocess('x, y') == ['x', 'y']
    assert Wrt.preprocess('x , y') == ['x', 'y']
    assert Wrt.preprocess(' x, y') == ['x', 'y']
    assert Wrt.preprocess(' x,  y') == ['x', 'y']
    assert Wrt.preprocess([x, y]) == ['x', 'y']

    raises(OptionError, "Wrt.preprocess(',')")
    raises(OptionError, "Wrt.preprocess(0)")
Beispiel #4
0
def test_Wrt_preprocess():
    assert Wrt.preprocess(x) == ['x']
    assert Wrt.preprocess('') == []
    assert Wrt.preprocess(' ') == []
    assert Wrt.preprocess('x,y') == ['x', 'y']
    assert Wrt.preprocess('x y') == ['x', 'y']
    assert Wrt.preprocess('x, y') == ['x', 'y']
    assert Wrt.preprocess('x , y') == ['x', 'y']
    assert Wrt.preprocess(' x, y') == ['x', 'y']
    assert Wrt.preprocess(' x,  y') == ['x', 'y']
    assert Wrt.preprocess([x, y]) == ['x', 'y']

    raises(OptionError, "Wrt.preprocess(',')")
    raises(OptionError, "Wrt.preprocess(0)")
def test_Wrt_postprocess():
    opt = {'wrt': ['x']}
    Wrt.postprocess(opt)

    assert opt == {'wrt': ['x']}
Beispiel #6
0
def test_Wrt_postprocess():
    opt = {'wrt': ['x']}
    Wrt.postprocess(opt)

    assert opt == {'wrt': ['x']}
Beispiel #7
0
def test_Wrt_postprocess():
    opt = {"wrt": ["x"]}
    Wrt.postprocess(opt)

    assert opt == {"wrt": ["x"]}