コード例 #1
0
ファイル: test_node.py プロジェクト: methane/markment
def test_node_list(os):
    ("Node#list should return a list containing one node "
     "per file found inside of the current node")
    os.listdir.return_value = ['/foo/bar/items/whatever.py']

    nd = Node('/foo/bar/items/')
    nd.list().should.have.length_of(1)

    os.listdir.assert_once_called_with('/foo/bar/items')