Skip to content

Commit

Permalink
Merge ba11661 into 0571620
Browse files Browse the repository at this point in the history
  • Loading branch information
oshi97 committed Oct 8, 2021
2 parents 0571620 + ba11661 commit 13da9be
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# This workflow will run our tests, generate an lcov code coverage file,
# and send that coverage to Coveralls

name: Code Coverage

on:
push:
branches-ignore: dev/*
pull_request:

jobs:
Coveralls:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Use Node.js 16.x
uses: actions/setup-node@v2
with:
node-version: 16.x
- run: npm ci
- run: npx jest --coverage
- name: Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@

# misc
.DS_Store
/coverage
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ It lets your React components read data from a answers-headless, and dispatch ac
<a href="./LICENSE">
<img src="https://img.shields.io/badge/License-BSD%203--Clause-blue.svg" alt="License"/>
</a>
<a href='https://coveralls.io/github/yext/answers-headless-react?branch=main'>
<img src='https://coveralls.io/repos/github/yext/answers-headless-react/badge.svg?branch=main' alt='Coverage Status' />
</a>
</div>
<br>

Expand Down
3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@
"jest": {
"bail": 0,
"verbose": true,
"collectCoverageFrom": [
"src/*.ts(x)?"
],
"setupFilesAfterEnv": [
"<rootDir>/tests/setup/setup-env.ts"
],
Expand Down

0 comments on commit 13da9be

Please sign in to comment.