From 4dc62c915aa5e5c166065fe1cd59436dca8995c3 Mon Sep 17 00:00:00 2001 From: Shwetha Radhakrishna Date: Mon, 31 Jan 2022 16:19:51 -0600 Subject: [PATCH 1/3] test: set the right version for tests --- .github/workflows/test-and-deploy.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/test-and-deploy.yml b/.github/workflows/test-and-deploy.yml index 2f3d6a5f8..b350e22e2 100644 --- a/.github/workflows/test-and-deploy.yml +++ b/.github/workflows/test-and-deploy.yml @@ -18,6 +18,8 @@ jobs: strategy: matrix: node: [ 6, 7, 8, 10, lts/* ] + env: + version: ${{ matrix.node }} steps: - name: Checkout sendgrid-nodejs uses: actions/checkout@v2 @@ -33,6 +35,10 @@ jobs: with: node-version: ${{ matrix.node }} + - name: Reset env vars + if: env.version == 'lts/*' + run: echo "version=lts" >> "$GITHUB_ENV" + - run: npm install - name: Run Tests run: make test-docker From 383d6d8e85d55667f35629cb7b2acb09d4ea5d7b Mon Sep 17 00:00:00 2001 From: Shwetha Radhakrishna Date: Mon, 31 Jan 2022 17:11:40 -0600 Subject: [PATCH 2/3] cleanup --- .github/workflows/test-and-deploy.yml | 6 ------ 1 file changed, 6 deletions(-) diff --git a/.github/workflows/test-and-deploy.yml b/.github/workflows/test-and-deploy.yml index b350e22e2..fa580cc7a 100644 --- a/.github/workflows/test-and-deploy.yml +++ b/.github/workflows/test-and-deploy.yml @@ -30,16 +30,10 @@ jobs: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_AUTH_TOKEN }} - - name: Set up Node - uses: actions/setup-node@v2 - with: - node-version: ${{ matrix.node }} - - name: Reset env vars if: env.version == 'lts/*' run: echo "version=lts" >> "$GITHUB_ENV" - - run: npm install - name: Run Tests run: make test-docker From eac2790b3bbd4cbdfe13f5dd8f00a3d70e4bf15f Mon Sep 17 00:00:00 2001 From: Shwetha Radhakrishna Date: Mon, 31 Jan 2022 17:15:09 -0600 Subject: [PATCH 3/3] more cleanup --- .github/workflows/test-and-deploy.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.github/workflows/test-and-deploy.yml b/.github/workflows/test-and-deploy.yml index fa580cc7a..1c6c882db 100644 --- a/.github/workflows/test-and-deploy.yml +++ b/.github/workflows/test-and-deploy.yml @@ -17,7 +17,7 @@ jobs: timeout-minutes: 20 strategy: matrix: - node: [ 6, 7, 8, 10, lts/* ] + node: [ 6, 7, 8, 10, lts ] env: version: ${{ matrix.node }} steps: @@ -30,10 +30,6 @@ jobs: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_AUTH_TOKEN }} - - name: Reset env vars - if: env.version == 'lts/*' - run: echo "version=lts" >> "$GITHUB_ENV" - - name: Run Tests run: make test-docker