Skip to content

Latest commit

 

History

History
67 lines (55 loc) · 2.09 KB

README.md

File metadata and controls

67 lines (55 loc) · 2.09 KB

GitHub Action Test

Description

GitHub Action that tests a node based repository

Usage

jobs:
  test:
    steps:
      - name: Test
        uses: open-turo/actions-node/test@v3
        with:
          ## example value for github-token provided below
          github-token: ${{ secrets.GITHUB_TOKEN }}

You can specify an S3 bucket to cache node_modules in order to speed up dependency installation, in which case you will need to configure AWS credentials like so:

jobs:
  build:
    steps:
      - uses: aws-actions/configure-aws-credentials@v4
          with:
          aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
          aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
      - uses: open-turo/actions-node/test@v5
        with:
          github-token: ${{ secrets.GITHUB_TOKEN }}
          s3-bucket-name: <bucket-name>
          s3-bucket-region: <bucket-region>

Notes

  • By default, this action will perform actions/checkout as its first step.

Inputs

parameter description required default
checkout-repo Perform checkout as first step of action false true
github-token GitHub token that can checkout the repository. e.g. 'secrets.GITHUB_TOKEN' true ${{ github.token }}
npm-auth-token The Node Package Manager (npm) authentication token. This token is used to authenticate against a private NPM registry configured via a .npmrc file. false
npm-token The Node Package Manager (npm) authentication token. This token is used to authenticate against the NPM registry. false
test-flags Flags and args for test command false

Runs

This action is a composite action.