blob: 2b6c21cce6afb88e13101526e2fc6c682d354a00 [file] [log] [blame]
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
# To learn more about GitHub Actions in Apache Beam check the CI.md
name: TypeScript Tests
on:
workflow_dispatch:
schedule:
- cron: '10 2 * * *'
push:
branches: ['master', 'release-*', 'javascript']
tags: 'v*'
pull_request:
branches: ['master', 'release-*', 'javascript']
tags: 'v*'
paths: ['sdks/typescript/**']
jobs:
typescript_unit_tests:
name: 'TypeScript Unit Tests'
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
persist-credentials: false
submodules: recursive
- name: Install node
uses: actions/setup-node@v2
with:
node-version: '16'
- run: npm ci
working-directory: ./sdks/typescript
- run: npm run build
working-directory: ./sdks/typescript
- run: npm run prettier-check
working-directory: ./sdks/typescript
if: ${{ matrix.os == 'ubuntu-latest' }}
# - run: npm run codecovTest
# working-directory: ./sdks/typescript
# if: ${{ matrix.os == 'ubuntu-latest' }}
- run: npm test
working-directory: ./sdks/typescript
# if: ${{ matrix.os != 'ubuntu-latest' }}