@patch('gonzo.contrib.checks.diff_branch')
    def test_upstream_changes(self, diff_branch):
        diff_branch.return_value = (1, 0)  # (upstream, local)

        with patch.object(sys, 'stderr', self.stderr):
            self._callFUT(current_release='origin/master')

        output = self.stderr.getvalue()
        expected_warning = checks.ASSERT_AHEAD_OF_CURRENT_RELEASE_WARNING
        expected_warning = expected_warning.format(
            'origin/master')
        assert expected_warning in output
dataset/ETHPy150Open onefinestay/gonzo/tests/contrib/test_checks.py/TestAssertAheadOfCurrentRelease.test_upstream_changes/original