generated from int128/typescript-action
-
Notifications
You must be signed in to change notification settings - Fork 2
83 lines (77 loc) · 3.13 KB
/
ts.yaml
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
name: ts
on:
push:
branches: [main]
paths:
- src/**
- tests/**
- '*.json'
- action.yaml
- .github/workflows/ts.yaml
pull_request:
branches: [main]
paths:
- src/**
- tests/**
- '*.json'
- action.yaml
- .github/workflows/ts.yaml
jobs:
ts:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
cache: yarn
- run: yarn
- run: yarn lint
- run: yarn format-check
- run: yarn test
- run: yarn build
- run: yarn package
- id: kustomize-single
uses: ./
with:
kustomization: tests/fixtures/overlays/*/kustomization.yaml
- run: find ${{ steps.kustomize-single.outputs.directory }}
- run: |
cat <<EOF
${{ steps.kustomize-single.outputs.files }}
EOF
- run: test -f ${{ steps.kustomize-single.outputs.directory }}/tests/fixtures/overlays/development/generated.yaml
- run: test -f ${{ steps.kustomize-single.outputs.directory }}/tests/fixtures/overlays/production/generated.yaml
- id: kustomize-individual
uses: ./
with:
kustomization: tests/fixtures/overlays/*/kustomization.yaml
write-individual-files: true
- run: find ${{ steps.kustomize-individual.outputs.directory }}
- run: |
cat <<EOF
${{ steps.kustomize-individual.outputs.files }}
EOF
- run: test -f ${{ steps.kustomize-individual.outputs.directory }}/tests/fixtures/overlays/development/v1_service_echoserver.yaml
- run: test -f ${{ steps.kustomize-individual.outputs.directory }}/tests/fixtures/overlays/development/apps_v1_deployment_echoserver.yaml
- run: test -f ${{ steps.kustomize-individual.outputs.directory }}/tests/fixtures/overlays/production/v1_service_echoserver.yaml
- run: test -f ${{ steps.kustomize-individual.outputs.directory }}/tests/fixtures/overlays/production/apps_v1_deployment_echoserver.yaml
- id: kustomize-single-with-extra-files
uses: ./
with:
kustomization: tests/fixtures/overlays/*/kustomization.yaml
extra-files: tests/fixtures/overlays/*/metadata.yaml
- run: find ${{ steps.kustomize-single-with-extra-files.outputs.directory }}
- run: |
cat <<EOF
${{ steps.kustomize-single-with-extra-files.outputs.files }}
EOF
- run: test -f ${{ steps.kustomize-single-with-extra-files.outputs.directory }}/tests/fixtures/overlays/development/generated.yaml
- run: test -f ${{ steps.kustomize-single-with-extra-files.outputs.directory }}/tests/fixtures/overlays/development/metadata.yaml
- run: test -f ${{ steps.kustomize-single-with-extra-files.outputs.directory }}/tests/fixtures/overlays/production/generated.yaml
- run: test ! -f ${{ steps.kustomize-single-with-extra-files.outputs.directory }}/tests/fixtures/overlays/production/metadata.yaml
- id: kustomize-error
uses: ./
with:
kustomization: tests/fixtures/invalid/kustomization.yaml
continue-on-error: true