Skip to content

Commit 455bf2d

Browse files
committed
test(lift): defined basic givens
1 parent 6fb4ff6 commit 455bf2d

File tree

4 files changed

+17
-2
lines changed

4 files changed

+17
-2
lines changed
Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
Feature: Lift
22

3-
Scenario: legacy semantic-release on GitHub Actions
3+
Scenario: legacy semantic-release in a GitHub workflow
4+
Given semantic-release is configured
5+
And legacy releases are configured in a GitHub workflow
46
When the project is lifted

test/integration/features/step_definitions/common-steps.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,10 @@ When('the project is lifted', async function () {
2828

2929
stubbedFs({
3030
node_modules: stubbedNodeModules,
31-
'package.json': JSON.stringify({...any.simpleObject()})
31+
'package.json': JSON.stringify({
32+
...any.simpleObject(),
33+
...this.semanticReleaseConfigured && {version: '0.0.0-semantically-released'}
34+
})
3235
});
3336

3437
if (await test({projectRoot})) {
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import {Given} from '@cucumber/cucumber';
2+
3+
Given('legacy releases are configured in a GitHub workflow', async function () {
4+
this.semanticReleaseGithubWorkflow = 'legacy';
5+
});
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import {Given} from '@cucumber/cucumber';
2+
3+
Given('semantic-release is configured', async function () {
4+
this.semanticReleaseConfigured = true;
5+
});

0 commit comments

Comments
 (0)