Skip to content

Commit

Permalink
chore: collect code coverage and upload to coveralls (#174)
Browse files Browse the repository at this point in the history
* chore: bump jest and related dependencies

* chore: add coverage npm script

* chore: enable coveralls code coverage upload

* chore: add custom override `yargs-parser` to fix failing build

This is required until kulshekhar/ts-jest#3741
is fixed.

* chore: fix typo in npm command in ci workflow

* chore: remove `package.json` override and just reinstall `ts-jest`

Co-authored-by: fenos <fabri.feno@gmail.com>
  • Loading branch information
bnjmnt4n and fenos committed Sep 1, 2022
1 parent 3cd3c91 commit 363f31c
Show file tree
Hide file tree
Showing 6 changed files with 1,527 additions and 2,478 deletions.
7 changes: 6 additions & 1 deletion .github/workflows/ci.yml
Expand Up @@ -49,7 +49,7 @@ jobs:
- name: Tests pass
run: |
npm test
npm run test:coverage
env:
ANON_KEY: ${{ secrets.ANON_KEY }}
SERVICE_KEY: ${{ secrets.SERVICE_KEY }}
Expand All @@ -66,3 +66,8 @@ jobs:
MULTITENANT_DATABASE_URL: postgresql://postgres:postgres@127.0.0.1:5433/postgres
POSTGREST_URL_SUFFIX: /rest/v1
ADMIN_API_KEYS: apikey

- name: Upload coverage results to Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
1 change: 1 addition & 0 deletions .gitignore
Expand Up @@ -7,4 +7,5 @@ dist/
static/api.json
data/
bin/
coverage/
.idea/
2 changes: 2 additions & 0 deletions README.md
@@ -1,5 +1,7 @@
# Supabase Storage Middleware

[![Coverage Status](https://coveralls.io/repos/github/supabase/storage-api/badge.svg?branch=master)](https://coveralls.io/github/supabase/storage-api?branch=master)

A scalable, light-weight object storage service.

> Read [this post](https://supabase.io/blog/2021/03/30/supabase-storage) on why we decided to build a new object storage service.
Expand Down
1 change: 1 addition & 0 deletions jest.config.js
Expand Up @@ -2,4 +2,5 @@ module.exports = {
preset: 'ts-jest',
testEnvironment: 'node',
testPathIgnorePatterns: ['node_modules', 'dist'],
coverageProvider: 'v8',
}

0 comments on commit 363f31c

Please sign in to comment.