-
Notifications
You must be signed in to change notification settings - Fork 3
47 lines (42 loc) · 1.08 KB
/
cloud-functions.yml
File metadata and controls
47 lines (42 loc) · 1.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: Cloud Functions
on:
pull_request:
branches:
- master
- develop
paths:
- .github/workflows/cloud-functions.yml
- "functions/**/*"
push:
branches:
- master
- develop
paths:
- .github/workflows/cloud-functions.yml
- "functions/**/*"
jobs:
test:
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
test: ["offline"]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 10
- name: Get YARN cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Activate YARN cache
uses: actions/cache@v1
id: yarn-cache
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- run: yarn --cwd functions install
- name: Run tests
run: yarn --cwd functions test:${{ matrix.test }}