Esempio n. 1
0
    def test_test(self, workspace):
        config = Config({
            'file': 'fake.py',
            'tests': 'test command',
        })
        releaser = Releaser(config)

        with patch('bumpr.releaser.execute') as execute:
            releaser.test()
            execute.assert_called_with('test command', replacements=ANY, dryrun=ANY, verbose=ANY)
Esempio n. 2
0
def test_test(workspace, mocker):
    config = Config({
        'file': 'fake.py',
        'tests': 'test command',
    })
    releaser = Releaser(config)
    execute = mocker.patch('bumpr.releaser.execute')

    releaser.test()

    execute.assert_called_with('test command', replacements=mocker.ANY, dryrun=mocker.ANY, verbose=mocker.ANY)
Esempio n. 3
0
    def test_skip_test(self, workspace):
        config = Config({
            'file': 'fake.py',
            'tests': 'test command',
            'skip_tests': True,
        })
        releaser = Releaser(config)

        with patch('bumpr.releaser.execute') as execute:
            releaser.test()
            assert not execute.called
Esempio n. 4
0
def test_skip_test(workspace, mocker):
    config = Config({
        'file': 'fake.py',
        'tests': 'test command',
        'skip_tests': True,
    })
    releaser = Releaser(config)
    execute = mocker.patch('bumpr.releaser.execute')

    releaser.test()

    assert not execute.called
Esempio n. 5
0
def test_skip_test(workspace, mocker):
    config = Config({
        "file": "fake.py",
        "tests": "test command",
        "skip_tests": True,
    })
    releaser = Releaser(config)
    execute = mocker.patch("bumpr.releaser.execute")

    releaser.test()

    assert not execute.called
Esempio n. 6
0
    def test_test(self):
        config = Config({
            'file': 'fake.py',
            'tests': 'test command',
        })
        with workspace('fake'):
            releaser = Releaser(config)

        with patch('bumpr.releaser.execute') as execute:
            releaser.test()
            execute.assert_called_with('test command',
                                       replacements=ANY,
                                       dryrun=ANY,
                                       verbose=ANY)
Esempio n. 7
0
def test_test(workspace, mocker):
    config = Config({
        "file": "fake.py",
        "tests": "test command",
    })
    releaser = Releaser(config)
    execute = mocker.patch("bumpr.releaser.execute")

    releaser.test()

    execute.assert_called_with("test command",
                               replacements=mocker.ANY,
                               dryrun=mocker.ANY,
                               verbose=mocker.ANY)