|
16 | 16 | # SPDX-License-Identifier: Apache-2.0 |
17 | 17 | on: |
18 | 18 | workflow_call: |
19 | | -name: Examples # not exactly right to test functionality in such a way but it does act as a set of end to end test cases for the time being, nevertheless should be updated |
| 19 | +# Not exactly right to test functionality in such a way, but it does act as a set of end-to-end test cases for the time |
| 20 | +# being, nevertheless should be updated |
| 21 | +name: Examples |
20 | 22 | jobs: |
21 | | - get-go-versions: |
22 | | - name: Collect available Go versions |
23 | | - runs-on: ubuntu-latest |
24 | | - outputs: |
25 | | - matrix: ${{ steps.versions.outputs.matrix }} |
26 | | - steps: |
27 | | - - uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 |
28 | | - - uses: arnested/go-version-action@b556f8d91b644164318c709d28b9083eaf0c064d |
29 | | - id: versions |
30 | 23 | client: |
31 | 24 | strategy: |
32 | 25 | fail-fast: false # Keep running if one leg fails. |
33 | 26 | matrix: |
34 | 27 | os: [ubuntu-latest, macos-latest, windows-latest] |
35 | | - go-version: ${{ fromJSON(needs.get-go-versions.outputs.matrix) }} |
36 | 28 | runs-on: ${{ matrix.os }} |
37 | | - needs: get-go-versions |
38 | 29 | steps: |
39 | 30 | - name: Checkout code |
40 | 31 | uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 |
41 | | - - name: Setup - Go ${{ matrix.go-version }} |
| 32 | + - name: Setup - Go |
42 | 33 | uses: actions/setup-go@c4a742cab115ed795e34d4513e2cf7d472deb55f |
43 | 34 | with: |
44 | | - go-version: ${{ matrix.go-version }} |
| 35 | + go-version-file: 'go.mod' |
| 36 | + cache: true |
45 | 37 | - run: make example-client |
| 38 | + |
46 | 39 | repository: |
47 | 40 | strategy: |
48 | 41 | fail-fast: false # Keep running if one leg fails. |
49 | 42 | matrix: |
50 | 43 | os: [ubuntu-latest, macos-latest, windows-latest] |
51 | | - go-version: ${{ fromJSON(needs.get-go-versions.outputs.matrix) }} |
52 | 44 | runs-on: ${{ matrix.os }} |
53 | | - needs: get-go-versions |
54 | 45 | steps: |
55 | 46 | - name: Checkout code |
56 | 47 | uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 |
57 | | - - name: Setup - Go ${{ matrix.go-version }} |
| 48 | + - name: Setup - Go |
58 | 49 | uses: actions/setup-go@c4a742cab115ed795e34d4513e2cf7d472deb55f |
59 | 50 | with: |
60 | | - go-version: ${{ matrix.go-version }} |
| 51 | + go-version-file: 'go.mod' |
| 52 | + cache: true |
61 | 53 | - run: make example-repository |
| 54 | + |
62 | 55 | multirepo: |
63 | 56 | strategy: |
64 | 57 | fail-fast: false # Keep running if one leg fails. |
65 | 58 | matrix: |
66 | 59 | os: [ubuntu-latest, macos-latest, windows-latest] |
67 | | - go-version: ${{ fromJSON(needs.get-go-versions.outputs.matrix) }} |
68 | 60 | runs-on: ${{ matrix.os }} |
69 | | - needs: get-go-versions |
70 | 61 | steps: |
71 | 62 | - name: Checkout code |
72 | 63 | uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 |
73 | | - - name: Setup - Go ${{ matrix.go-version }} |
| 64 | + - name: Setup - Go |
74 | 65 | uses: actions/setup-go@c4a742cab115ed795e34d4513e2cf7d472deb55f |
75 | 66 | with: |
76 | | - go-version: ${{ matrix.go-version }} |
| 67 | + go-version-file: 'go.mod' |
| 68 | + cache: true |
77 | 69 | - run: make example-multirepo |
| 70 | + |
78 | 71 | tuf-client-cli: |
79 | 72 | strategy: |
80 | 73 | fail-fast: false # Keep running if one leg fails. |
81 | 74 | matrix: |
82 | 75 | os: [ubuntu-latest, macos-latest, windows-latest] |
83 | | - go-version: ${{ fromJSON(needs.get-go-versions.outputs.matrix) }} |
84 | 76 | runs-on: ${{ matrix.os }} |
85 | | - needs: get-go-versions |
86 | 77 | steps: |
87 | 78 | - name: Checkout code |
88 | 79 | uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 |
89 | | - - name: Setup - Go ${{ matrix.go-version }} |
| 80 | + - name: Setup - Go |
90 | 81 | uses: actions/setup-go@c4a742cab115ed795e34d4513e2cf7d472deb55f |
91 | 82 | with: |
92 | | - go-version: ${{ matrix.go-version }} |
| 83 | + go-version-file: 'go.mod' |
| 84 | + cache: true |
93 | 85 | - run: make example-tuf-client-cli |
| 86 | + |
94 | 87 | root-signing: |
95 | 88 | strategy: |
96 | 89 | fail-fast: false # Keep running if one leg fails. |
97 | 90 | matrix: |
98 | 91 | os: [ubuntu-latest, macos-latest, windows-latest] |
99 | | - go-version: ${{ fromJSON(needs.get-go-versions.outputs.matrix) }} |
100 | 92 | runs-on: ${{ matrix.os }} |
101 | | - needs: get-go-versions |
102 | 93 | steps: |
103 | 94 | - name: Checkout code |
104 | 95 | uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 |
105 | | - - name: Setup - Go ${{ matrix.go-version }} |
| 96 | + - name: Setup - Go |
106 | 97 | uses: actions/setup-go@c4a742cab115ed795e34d4513e2cf7d472deb55f |
107 | 98 | with: |
108 | | - go-version: ${{ matrix.go-version }} |
| 99 | + go-version-file: 'go.mod' |
| 100 | + cache: true |
109 | 101 | - run: make example-root-signing |
0 commit comments