Skip to content

Commit

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

name: Code Coverage

on: [push, pull_request]

jobs:
Coveralls:
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [16.x]

steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: git config --global user.email "slapshot@yext.com"
- run: git config --global user.name "Jambo run-tests.yml"
- run: npx jest --config=jest-coverage.json
- run: ls
- name: Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Jambo

<div>
<a href='https://coveralls.io/github/yext/jambo?branch=master'>
<img src='https://coveralls.io/repos/github/yext/jambo/badge.svg?branch=master' alt='Coverage Status' />
</a>
</div>

Jambo is a JAMStack implementation using Handlebars.

## Installation
Expand Down
15 changes: 15 additions & 0 deletions jest-coverage.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"collectCoverage": true,
"collectCoverageFrom": ["src/**"],
"setupFilesAfterEnv": [
"./tests/setup/setup.js"
],
"testMatch": [
"**/tests/**/*.js"
],
"testPathIgnorePatterns": [
"<rootDir>/tests/fixtures/",
"<rootDir>/tests/setup/",
"<rootDir>/tests/acceptance/"
]
}
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
"shell-quote": "^1.7.2"
},
"jest": {
"collectCoverageFrom": ["src/**"],
"verbose": true,
"setupFilesAfterEnv": [
"./tests/setup/setup.js"
Expand Down

0 comments on commit 289b6c6

Please sign in to comment.