コード例 #1
0
def test_get_changed_files():
    files = get_changed_files(
        '78c682a1d13ba20e7cb735313b9314a74365cd3a',
        '3387edbb1288a580b37fe25225aa0b856b18ad1a',
    )
    assert files == ['CHANGELOG.md', 'setup.py']

    # files changed in source but not in origin should not be returned
    files = get_changed_files('HEAD~10', 'HEAD')
    assert files == []
コード例 #2
0
def test_get_changed_files():
    files = get_changed_files(
        '78c682a1d13ba20e7cb735313b9314a74365cd3a',
        '3387edbb1288a580b37fe25225aa0b856b18ad1a',
    )
    assert files == ['CHANGELOG.md', 'setup.py']

    # files changed in source but not in origin should not be returned
    files = get_changed_files('HEAD~10', 'HEAD')
    assert files == []
コード例 #3
0
ファイル: run_test.py プロジェクト: akramhussein/pre-commit
def test_get_changed_files():
    files = get_changed_files(
        '78c682a1d13ba20e7cb735313b9314a74365cd3a',
        '3387edbb1288a580b37fe25225aa0b856b18ad1a',
    )
    assert files == ['CHANGELOG.md', 'setup.py']
コード例 #4
0
ファイル: run_test.py プロジェクト: face-water/pre-push
def test_get_changed_files():
    files = list(
        get_changed_files('78c682a1d13ba20e7cb735313b9314a74365cd3a',
                          '3387edbb1288a580b37fe25225aa0b856b18ad1a'))
    assert files == ['CHANGELOG.md', 'setup.py']