def test_prepare_with_version(self): self.releaser.config[ReplaceHook.key] = { 'dev': 'dev-{version}', 'stable': 'stable-{tag}', } replacements = [] hook = ReplaceHook(self.releaser) hook.prepare(replacements) assert replacements == [('stable-v1.2.3', 'dev-1.2.4.dev')]
def test_bump(self): self.releaser.config[ReplaceHook.key] = { 'dev': 'dev-{version}', 'stable': 'stable-{tag}', } replacements = [] hook = ReplaceHook(self.releaser) hook.bump(replacements) assert replacements == [('dev-1.2.3.dev', 'stable-v1.2.3')]
def test_prepare_with_version(self): self.releaser.config[ReplaceHook.key] = { "dev": "dev-{version}", "stable": "stable-{tag}", } replacements = [] hook = ReplaceHook(self.releaser) hook.prepare(replacements) assert replacements == [("stable-v1.2.3", "dev-1.2.4.dev")]
def test_bump(self): self.releaser.config[ReplaceHook.key] = { "dev": "dev-{version}", "stable": "stable-{tag}", } replacements = [] hook = ReplaceHook(self.releaser) hook.bump(replacements) assert replacements == [("dev-1.2.3.dev", "stable-v1.2.3")]