Merge pull request #19 from kevinveenbirkenbach/feature/release-expect-tree
feat(release): refuse a release whose HEAD tree is not the audited one
This commit is contained in:
13 files changed
+527
-303
No files matched your search
@@ -10,6 +10,7 @@ from contextlib import redirect_stdout, suppress
|
||||
from pathlib import Path
|
||||
from unittest.mock import patch
|
||||
|
||||
from pkgmgr.actions.release.options import ReleaseOptions
|
||||
from pkgmgr.actions.release.retry import retry_release
|
||||
from pkgmgr.actions.release.workflow import _release_impl
|
||||
from pkgmgr.actions.repository.push import (
|
||||
@@ -381,7 +382,11 @@ class TestPushMirrorLeases(unittest.TestCase):
|
||||
|
||||
with redirect_stdout(io.StringIO()), self.assertRaises(PushRefusedError):
|
||||
_release_impl(
|
||||
pyproject_path=os.path.join(self.repo, "pyproject.toml"), force=True
|
||||
ReleaseOptions(
|
||||
pyproject_path=os.path.join(self.repo, "pyproject.toml"),
|
||||
force=True,
|
||||
expect_tree=None,
|
||||
)
|
||||
)
|
||||
|
||||
self.assertEqual(git(self.repo, "rev-parse", "HEAD"), head)
|
||||
|
||||
Reference in new issue
Block a user