Beispiel #1
0
def test_clone_or_update():
    path = settings['WORKSPACE'] + '/test_clone'

    assert not (git.exists(path)), 'Directory should not exist.'
    git.clone_or_update(config, 'git://github.com/markstory/lint-review.git',
                        path, 'e4f880c77e6b2c81c81cad5d45dd4e1c39b919a0')
    assert git.exists(path)
    git.destroy(path)
Beispiel #2
0
 def test_repo_operations(self):
     teardown_repo()
     res = git.clone(
         'git://github.com/markstory/lint-review.git',
         clone_path)
     assert res, 'Cloned successfully.'
     assert git.exists(clone_path), 'Cloned dir should be there.'
     git.destroy(clone_path)
     assert not(git.exists(clone_path)), 'Cloned dir should be gone.'
Beispiel #3
0
def test_repo_operations():
    path = settings['WORKSPACE'] + '/test_clone'

    assert not (git.exists(path)), 'Directory should not exist.'
    res = git.clone('git://github.com/markstory/lint-review.git', path)
    assert res, 'Cloned successfully.'
    assert git.exists(path), 'Cloned dir should be there.'
    git.destroy(path)
    assert not (git.exists(path)), 'Cloned dir should be gone.'
Beispiel #4
0
def test_clone_or_update():
    path = settings["WORKSPACE"] + "/test_clone"

    assert not (git.exists(path)), "Directory should not exist."
    git.clone_or_update(
        config, "git://github.com/markstory/lint-review.git", path, "e4f880c77e6b2c81c81cad5d45dd4e1c39b919a0"
    )
    assert git.exists(path)
    git.destroy(path)
Beispiel #5
0
def test_repo_operations():
    path = settings["WORKSPACE"] + "/test_clone"

    assert not (git.exists(path)), "Directory should not exist."
    res = git.clone("git://github.com/markstory/lint-review.git", path)
    assert res, "Cloned successfully."
    assert git.exists(path), "Cloned dir should be there."
    git.destroy(path)
    assert not (git.exists(path)), "Cloned dir should be gone."
Beispiel #6
0
def test_clone_or_update():
    path = settings['WORKSPACE'] + '/test_clone'

    assert not(git.exists(path)), 'Directory should not exist.'
    git.clone_or_update(
        'git://github.com/markstory/lint-review.git',
        path,
        'e4f880c77e6b2c81c81cad5d45dd4e1c39b919a0')
    assert git.exists(path)
    git.destroy(path)
Beispiel #7
0
def test_repo_operations():
    path = settings['WORKSPACE'] + '/test_clone'

    assert not(git.exists(path)), 'Directory should not exist.'
    res = git.clone(
        'git://github.com/markstory/lint-review.git',
        path)
    assert res, 'Cloned successfully.'
    assert git.exists(path), 'Cloned dir should be there.'
    git.destroy(path)
    assert not(git.exists(path)), 'Cloned dir should be gone.'
Beispiel #8
0
 def test_clone_or_update(self, mock_fetch, mock_checkout):
     teardown_repo()
     git.clone_or_update(
         config,
         'git://github.com/markstory/lint-review.git',
         clone_path,
         'e4f880c77e6b2c81c81cad5d45dd4e1c39b919a0')
     assert git.exists(clone_path)
Beispiel #9
0
def test_exists__no_git():
    assert not git.exists(settings['WORKSPACE'])
Beispiel #10
0
def test_exists__no_path():
    assert not git.exists(settings['WORKSPACE'] + '/herp/derp')
Beispiel #11
0
def teardown_repo():
    if git.exists(clone_path):
        git.destroy(clone_path)
Beispiel #12
0
def test_clone_or_update():
    git.clone_or_update(config, 'git://github.com/markstory/lint-review.git',
                        clone_path, 'e4f880c77e6b2c81c81cad5d45dd4e1c39b919a0')
    assert git.exists(clone_path)
Beispiel #13
0
def test_exists__no_git():
    assert not git.exists(settings['WORKSPACE'])
Beispiel #14
0
def test_exists__no_path():
    assert not git.exists(settings['WORKSPACE'] + '/herp/derp')
Beispiel #15
0
def teardown_repo():
    if git.exists(clone_path):
        git.destroy(clone_path)
Beispiel #16
0
def test_exists__no_path():
    assert not git.exists(settings["WORKSPACE"] + "/herp/derp")