From c1925c29bdaca993b5d63f4971820f8f026b61f1 Mon Sep 17 00:00:00 2001 From: Matt Wise <768067+diranged@users.noreply.github.com> Date: Sun, 11 Feb 2024 07:58:27 -0800 Subject: [PATCH] chore(deps): upgrade github actions workflows to the latest components (#17) Co-authored-by: Matt Wise --- src/pipeline.ts | 2 +- test/__snapshots__/github.test.ts.snap | 24 +++++++++---------- .../runner-provided.test.ts.snap | 2 +- test/__snapshots__/stage-options.test.ts.snap | 22 ++++++++--------- test/stage-options.test.ts | 10 ++++---- 5 files changed, 30 insertions(+), 30 deletions(-) diff --git a/src/pipeline.ts b/src/pipeline.ts index 7e0232a5..602083de 100644 --- a/src/pipeline.ts +++ b/src/pipeline.ts @@ -629,7 +629,7 @@ export class GitHubWorkflow extends PipelineBase { return [ { name: 'Checkout', - uses: 'actions/checkout@v3', + uses: 'actions/checkout@v4', }, ]; } diff --git a/test/__snapshots__/github.test.ts.snap b/test/__snapshots__/github.test.ts.snap index 8805a223..eff2d4c8 100644 --- a/test/__snapshots__/github.test.ts.snap +++ b/test/__snapshots__/github.test.ts.snap @@ -23,7 +23,7 @@ jobs: image: alpine steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - uses: actions/setup-node@v3 with: node-version: "16" @@ -213,7 +213,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via GitHub Secrets @@ -261,7 +261,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Build @@ -302,7 +302,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Build @@ -340,7 +340,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via GitHub Secrets @@ -414,7 +414,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via OIDC Role @@ -487,7 +487,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Authenticate Via GitHub Secrets uses: aws-actions/configure-aws-credentials@v4 with: @@ -558,7 +558,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Build @@ -596,7 +596,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Authenticate Via GitHub Secrets uses: aws-actions/configure-aws-credentials@v4 with: @@ -669,7 +669,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via GitHub Secrets @@ -715,7 +715,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Authenticate Via GitHub Secrets uses: aws-actions/configure-aws-credentials@v4 with: @@ -787,7 +787,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Authenticate Via GitHub Secrets uses: aws-actions/configure-aws-credentials@v4 with: diff --git a/test/__snapshots__/runner-provided.test.ts.snap b/test/__snapshots__/runner-provided.test.ts.snap index 3ef53ae0..23335175 100644 --- a/test/__snapshots__/runner-provided.test.ts.snap +++ b/test/__snapshots__/runner-provided.test.ts.snap @@ -21,7 +21,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Build diff --git a/test/__snapshots__/stage-options.test.ts.snap b/test/__snapshots__/stage-options.test.ts.snap index b069ff90..97757d78 100644 --- a/test/__snapshots__/stage-options.test.ts.snap +++ b/test/__snapshots__/stage-options.test.ts.snap @@ -22,7 +22,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via GitHub Secrets @@ -99,7 +99,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: post deploy action uses: my-post-deploy-action@1.0.0 with: @@ -129,7 +129,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via GitHub Secrets @@ -201,7 +201,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via GitHub Secrets @@ -273,7 +273,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via OIDC Role @@ -397,7 +397,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via GitHub Secrets @@ -500,7 +500,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via GitHub Secrets @@ -608,7 +608,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: post wave action uses: my-post-wave-action@1.0.0 with: @@ -638,7 +638,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via GitHub Secrets @@ -711,7 +711,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via GitHub Secrets @@ -811,7 +811,7 @@ jobs: env: {} steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Install run: yarn - name: Authenticate Via GitHub Secrets diff --git a/test/stage-options.test.ts b/test/stage-options.test.ts index 6aab8284..b626aeae 100644 --- a/test/stage-options.test.ts +++ b/test/stage-options.test.ts @@ -275,7 +275,7 @@ test('can set pre/post github action job step', () => { jobSteps: [ { name: 'Checkout', - uses: 'actions/checkout@v3', + uses: 'actions/checkout@v4', }, { name: 'post deploy action', @@ -296,7 +296,7 @@ test('can set pre/post github action job step', () => { expect(workflowFileContents).toMatchSnapshot(); expect(workflowFileContents).toContain('my-pre-deploy-action@1.0.0'); expect(workflowFileContents).toContain('my-post-deploy-action@1.0.0'); - expect(workflowFileContents).toContain('actions/checkout@v3'); + expect(workflowFileContents).toContain('actions/checkout@v4'); expect(workflowFileContents).toContain('contains(fromJson(\'["push", "pull_request"]\'), github.event_name)'); expect(workflowFileContents).toContain("success() && contains(github.event.issue.labels.*.name, 'deploy')"); }); @@ -417,7 +417,7 @@ test('github stages in waves works', () => { jobSteps: [ { name: 'Checkout', - uses: 'actions/checkout@v3', + uses: 'actions/checkout@v4', }, { name: 'post wave action', @@ -495,7 +495,7 @@ test('stages in pipeline works with `if`', () => { const workflowFileContents = readFileSync(pipeline.workflowPath, 'utf-8'); expect(workflowFileContents).toMatchSnapshot(); - expect(workflowFileContents).toContain('actions/checkout@v3'); + expect(workflowFileContents).toContain('actions/checkout@v4'); const yaml = YAML.parse(workflowFileContents); expect(yaml).toMatchObject({ @@ -550,7 +550,7 @@ test('create stages with different awsCreds', () => { const workflowFileContents = readFileSync(pipeline.workflowPath, 'utf-8'); expect(workflowFileContents).toMatchSnapshot(); - expect(workflowFileContents).toContain('actions/checkout@v3'); + expect(workflowFileContents).toContain('actions/checkout@v4'); const yaml = YAML.parse(workflowFileContents); expect(yaml).toMatchObject({