generated from actions/typescript-action
-
-
Notifications
You must be signed in to change notification settings - Fork 5
106 lines (94 loc) · 3.74 KB
/
default.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
name: Default
on:
push:
branches-ignore:
- main
jobs:
default:
name: Default
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: npm install
- run: npm run all
- uses: ./
id: test-1
with:
version: wrong
lenient: false
continue-on-error: true
- run: '[[ "failure" == "${{ steps.test-1.outcome }}" ]]'
- run: '[[ "success" == "${{ steps.test-1.conclusion }}" ]]'
- uses: ./
id: test-2
with:
version: wrong
lenient: 'false'
continue-on-error: true
- run: '[[ "failure" == "${{ steps.test-2.outcome }}" ]]'
- run: '[[ "success" == "${{ steps.test-2.conclusion }}" ]]'
- uses: ./
id: test-3
with:
version: wrong
- run: '[[ "" == "${{ steps.test-3.outputs.release }}" ]]'
- run: '[[ "" == "${{ steps.test-3.outputs.major }}" ]]'
- run: '[[ "" == "${{ steps.test-3.outputs.minor }}" ]]'
- run: '[[ "" == "${{ steps.test-3.outputs.patch }}" ]]'
- run: '[[ "" == "${{ steps.test-3.outputs.any_other_property }}" ]]'
- uses: ./
id: test-4
with:
version: wrong
lenient: true
- run: '[[ "" == "${{ steps.test-4.outputs.release }}" ]]'
- run: '[[ "" == "${{ steps.test-4.outputs.major }}" ]]'
- run: '[[ "" == "${{ steps.test-4.outputs.minor }}" ]]'
- run: '[[ "" == "${{ steps.test-4.outputs.patch }}" ]]'
- run: '[[ "" == "${{ steps.test-4.outputs.any_other_property }}" ]]'
- uses: ./
id: test-5
with:
version: 1.2.3-alpha.gamma+4.5.6
- run: '[[ "1.2.3" == "${{ steps.test-5.outputs.release }}" ]]'
- run: '[[ "1" == "${{ steps.test-5.outputs.major }}" ]]'
- run: '[[ "2" == "${{ steps.test-5.outputs.minor }}" ]]'
- run: '[[ "3" == "${{ steps.test-5.outputs.patch }}" ]]'
- run: '[[ "alpha.gamma" == "${{ steps.test-5.outputs.prerelease }}" ]]'
- run: '[[ "2" == "${{ steps.test-5.outputs.prerelease-parts }}" ]]'
- run: '[[ "alpha" == "${{ steps.test-5.outputs.prerelease-0 }}" ]]'
- run: '[[ "gamma" == "${{ steps.test-5.outputs.prerelease-1 }}" ]]'
- run: '[[ "4.5.6" == "${{ steps.test-5.outputs.build }}" ]]'
- run: '[[ "3" == "${{ steps.test-5.outputs.build-parts }}" ]]'
- run: '[[ "4" == "${{ steps.test-5.outputs.build-0 }}" ]]'
- run: '[[ "5" == "${{ steps.test-5.outputs.build-1 }}" ]]'
- run: '[[ "6" == "${{ steps.test-5.outputs.build-2 }}" ]]'
- uses: ./
id: test-6
with:
version: 1.0.0
compare-to: 2.0.0
- run: '[[ "<" == "${{ steps.test-6.outputs.comparison-result }}" ]]'
- uses: ./
id: test-7
with:
version: 1.2.3
satisfies: 1.x
- run: '[[ "true" == "${{ steps.test-7.outputs.satisfies }}" ]]'
- uses: ./
id: test-8
with:
version: 1.2.3
- run: '[[ "2.0.0" == "${{ steps.test-8.outputs.inc-major }}" ]]'
- run: '[[ "2.0.0-0" == "${{ steps.test-8.outputs.inc-premajor }}" ]]'
- run: '[[ "1.3.0" == "${{ steps.test-8.outputs.inc-minor }}" ]]'
- run: '[[ "1.3.0-0" == "${{ steps.test-8.outputs.inc-preminor }}" ]]'
- run: '[[ "1.2.4" == "${{ steps.test-8.outputs.inc-patch }}" ]]'
- run: '[[ "1.2.4-0" == "${{ steps.test-8.outputs.inc-prepatch }}" ]]'
- run: '[[ "1.2.4-0" == "${{ steps.test-8.outputs.inc-prerelease }}" ]]'
actions-typing:
name: Validate actions typing
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: typesafegithub/github-actions-typing@v1