update-snapshots #804
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: update-snapshots | |
on: | |
schedule: | |
- cron: "0 15 * * *" # every day 11am EST | |
jobs: | |
check: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Set up Node 14 | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 14 | |
- name: Set up Docker Buildx | |
id: buildx | |
uses: docker/setup-buildx-action@v2 | |
- name: Complete Buildx Setup | |
run: docker run --privileged --rm tonistiigi/binfmt --install all | |
- name: Get yarn cache directory path | |
id: yarn-cache-dir-path | |
run: echo "dir=$(yarn cache dir)" >> "$GITHUB_OUTPUT" | |
- name: Restore node modules from cache | |
id: cache-node-modules | |
uses: actions/cache@v3 | |
with: | |
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} | |
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: | | |
${{ runner.os }}-yarn- | |
- name: Install Serverless Framework | |
run: sudo yarn global add serverless --prefix /usr/local | |
- name: Install dependencies | |
working-directory: integration_tests | |
run: yarn install | |
- name: Update Snapshots | |
env: | |
UPDATE_SNAPSHOTS: true | |
BUILD_LAYERS: true | |
DD_API_KEY: ${{ secrets.DD_API_KEY }} | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
run: ./scripts/run_integration_tests.sh | |
- name: Create Pull Request | |
uses: peter-evans/create-pull-request@v3 | |
with: | |
commit-message: update snapshots | |
title: Update Snapshots | |
body: | | |
Autogenerated PR to update integration test snapshots. Make sure no difference when run in local environment before merging. | |
branch: update-snapshots |