示例#1
0
def test_lookstr():
    
    table = (('foo', 'bar'), ('a', 1), ('b', 2))
    actual = repr(lookstr(table))
    expect = """+-----+-----+
| foo | bar |
+=====+=====+
| a   | 1   |
+-----+-----+
| b   | 2   |
+-----+-----+
"""
    eq_(expect, actual)
示例#2
0
def test_lookstr():

    table = (('foo', 'bar'), ('a', 1), ('b', 2))
    actual = repr(lookstr(table))
    expect = """+-----+-----+
| foo | bar |
+=====+=====+
| a   |   1 |
+-----+-----+
| b   |   2 |
+-----+-----+
"""
    eq_(expect, actual)
示例#3
0
文件: test_util.py 项目: talwai/petl
def test_lookstr():

    table = (("foo", "bar"), ("a", 1), ("b", 2))
    actual = repr(lookstr(table))
    expect = """+-----+-----+
| foo | bar |
+=====+=====+
| a   |   1 |
+-----+-----+
| b   |   2 |
+-----+-----+
"""
    eq_(expect, actual)