Beispiel #1
0
def test_maybe_add_simple_index_already_there():
    dist = Distribution()
    cmd = develop(dist)

    actual = cmd.maybe_add_simple_index('http://foo/simple')
    assert actual == 'http://foo/simple'

    actual = cmd.maybe_add_simple_index('http://foo/simple/')
    assert actual == 'http://foo/simple/'
Beispiel #2
0
def test_maybe_add_simple_index_empty():
    dist = Distribution()
    cmd = develop(dist)
    assert cmd.maybe_add_simple_index('') == ''
Beispiel #3
0
def test_maybe_add_simple_index_develop():
    dist = Distribution()
    cmd = develop(dist)
    assert cmd.maybe_add_simple_index('http://foo') == 'http://foo/simple'
Beispiel #4
0
def test_maybe_add_simple_index_develop():
    with patch.object(base, 'CONFIG', TEST_CONFIG):
        dist = Distribution()
        cmd = develop.develop(dist)
        assert cmd.maybe_add_simple_index('http://foo') == 'http://foo/simple'
def test_maybe_add_simple_index_empty():
    with patch.object(base, 'CONFIG', TEST_CONFIG):
        dist = Distribution()
        cmd = develop(dist)
        assert cmd.maybe_add_simple_index('') == ''