Esempio n. 1
0
def test_expand_directories_flattens_expanded_directories():
    flexmock(module).should_receive('_expand_directory').with_args('~/foo').and_return(['/root/foo'])
    flexmock(module).should_receive('_expand_directory').with_args('bar*').and_return(['bar', 'barf'])

    paths = module._expand_directories(('~/foo', 'bar*'))

    assert paths == ('/root/foo', 'bar', 'barf')
Esempio n. 2
0
def test_expand_directories_considers_none_as_no_directories():
    paths = module._expand_directories(None)

    assert paths == ()