mirror of
https://github.com/IT4Change/Ocelot-Social.git
synced 2025-12-13 07:45:56 +00:00
Merge pull request #569 from Human-Connection/2019/kw19/codecov
2019/kw19/codecov
This commit is contained in:
commit
1e321dec7d
163
.codecov.yml
Normal file
163
.codecov.yml
Normal file
@ -0,0 +1,163 @@
|
|||||||
|
codecov:
|
||||||
|
#token: uuid # Your private repository token
|
||||||
|
#url: "http" # for Codecov Enterprise customers
|
||||||
|
#slug: "owner/repo" # for Codecov Enterprise customers
|
||||||
|
#branch: master # override the default branch
|
||||||
|
#bot: username # set user whom will be the consumer of oauth requests
|
||||||
|
#ci: # Custom CI domains if Codecov does not identify them automatically
|
||||||
|
# - ci.domain.com
|
||||||
|
# - !provider # ignore these providers when checking if CI passed
|
||||||
|
# # ex. You may test on Travis, Circle, and AppVeyor, but only need
|
||||||
|
# # to check if Travis passes. Therefore add: !circle and !appveyor
|
||||||
|
notify:
|
||||||
|
#after_n_builds: null # number of expected builds to recieve before sending notifications
|
||||||
|
# # after: check ci status unless disabled via require_ci_to_pass
|
||||||
|
require_ci_to_pass: yes # yes: will delay sending notifications until all ci is finished
|
||||||
|
# no: will send notifications without checking ci status and wait till "after_n_builds" are uploaded
|
||||||
|
#countdown: null # number of seconds to wait before first ci build check
|
||||||
|
#delay: null # number of seconds to wait between ci build checks
|
||||||
|
|
||||||
|
coverage:
|
||||||
|
precision: 2 # 2 = xx.xx%, 0 = xx%
|
||||||
|
round: nearest # down|up|nearest - default down
|
||||||
|
# range: 50...60 # default 70...90. red...green
|
||||||
|
|
||||||
|
#notify:
|
||||||
|
# irc:
|
||||||
|
# default:
|
||||||
|
# server: "chat.freenode.net"|encrypted
|
||||||
|
# branches: null # all branches by default
|
||||||
|
# threshold: 1%
|
||||||
|
# message: "Coverage {{changed}} for {{owner}}/{{repo}}" # customize the message
|
||||||
|
# flags: null
|
||||||
|
# paths: null
|
||||||
|
#
|
||||||
|
# slack:
|
||||||
|
# default:
|
||||||
|
# url: "http"|encrypted
|
||||||
|
# threshold: 1%
|
||||||
|
# branches: null # all branches by default
|
||||||
|
# message: "Coverage {{changed}} for {{owner}}/{{repo}}" # customize the message
|
||||||
|
# attachments: "sunburst, diff"
|
||||||
|
# only_pulls: false
|
||||||
|
# flags: null
|
||||||
|
# paths: null
|
||||||
|
#
|
||||||
|
# email:
|
||||||
|
# default:
|
||||||
|
# to:
|
||||||
|
# - example@domain.com
|
||||||
|
# - &author
|
||||||
|
# threshold: 1%
|
||||||
|
# only_pulls: false
|
||||||
|
# layout: header, diff, trends
|
||||||
|
# flags: null
|
||||||
|
# paths: null
|
||||||
|
#
|
||||||
|
# hipchat:
|
||||||
|
# default:
|
||||||
|
# url: "http"|encrypted
|
||||||
|
# room: name|id
|
||||||
|
# threshold: 1%
|
||||||
|
# token: encrypted
|
||||||
|
# branches: null # all branches by default
|
||||||
|
# notify: false # if the hipchat message is silent or loud (default false)
|
||||||
|
# message: "Coverage {{changed}} for {{owner}}/{{repo}}" # customize the message
|
||||||
|
# flags: null
|
||||||
|
# paths: null
|
||||||
|
#
|
||||||
|
# gitter:
|
||||||
|
# url: "http"|encrypted
|
||||||
|
# threshold: 1%
|
||||||
|
# branches: null # all branches by default
|
||||||
|
# message: "Coverage {{changed}} for {{owner}}/{{repo}}" # customize the message
|
||||||
|
#
|
||||||
|
# webhooks:
|
||||||
|
# _name_:
|
||||||
|
# url: "http"|encrypted
|
||||||
|
# threshold: 1%
|
||||||
|
# branches: null # all branches by default
|
||||||
|
|
||||||
|
status:
|
||||||
|
project:
|
||||||
|
default: false # disable the default status that measures entire project
|
||||||
|
backend: # declare a new status context "backend"
|
||||||
|
against: parent
|
||||||
|
target: auto
|
||||||
|
threshold: null
|
||||||
|
#threshold: 1%
|
||||||
|
base: auto
|
||||||
|
if_no_uploads: error
|
||||||
|
if_not_found: success
|
||||||
|
if_ci_failed: error
|
||||||
|
only_pulls: false
|
||||||
|
#branches:
|
||||||
|
# - master
|
||||||
|
#flags:
|
||||||
|
# - integration
|
||||||
|
paths:
|
||||||
|
- backend/ # only include coverage in "backend/" folder
|
||||||
|
webapp: # declare a new status context "frontend"
|
||||||
|
against: parent
|
||||||
|
target: auto
|
||||||
|
threshold: null
|
||||||
|
#threshold: 1%
|
||||||
|
base: auto
|
||||||
|
if_no_uploads: error
|
||||||
|
if_not_found: success
|
||||||
|
if_ci_failed: error
|
||||||
|
only_pulls: false
|
||||||
|
#branches:
|
||||||
|
# - master
|
||||||
|
#flags:
|
||||||
|
# - integration
|
||||||
|
paths:
|
||||||
|
- webapp/ # only include coverage in "webapp/" folder
|
||||||
|
|
||||||
|
#patch:
|
||||||
|
# default:
|
||||||
|
# against: parent
|
||||||
|
# target: 80%
|
||||||
|
# branches: null
|
||||||
|
# if_no_uploads: success
|
||||||
|
# if_not_found: success
|
||||||
|
# if_ci_failed: error
|
||||||
|
# only_pulls: false
|
||||||
|
# flags:
|
||||||
|
# - integration
|
||||||
|
# paths:
|
||||||
|
# - folder
|
||||||
|
|
||||||
|
#changes:
|
||||||
|
# default:
|
||||||
|
# against: parent
|
||||||
|
# branches: null
|
||||||
|
# if_no_uploads: error
|
||||||
|
# if_not_found: success
|
||||||
|
# if_ci_failed: error
|
||||||
|
# only_pulls: false
|
||||||
|
# flags:
|
||||||
|
# - integration
|
||||||
|
# paths:
|
||||||
|
# - folder
|
||||||
|
|
||||||
|
#flags:
|
||||||
|
# integration:
|
||||||
|
# branches:
|
||||||
|
# - master
|
||||||
|
# ignore:
|
||||||
|
# - app/ui
|
||||||
|
|
||||||
|
#ignore: # files and folders for processing
|
||||||
|
# - tests/*
|
||||||
|
|
||||||
|
#fixes:
|
||||||
|
# - "old_path::new_path"
|
||||||
|
|
||||||
|
comment:
|
||||||
|
layout: header, diff, trends, uncovered, reach, files, tree, changes, sunburst, flags
|
||||||
|
branches: *
|
||||||
|
behavior: new # default = posts once then update, posts new if delete
|
||||||
|
# once = post once then updates
|
||||||
|
# new = delete old, post new
|
||||||
|
# spammy = post new
|
||||||
@ -10,6 +10,8 @@ addons:
|
|||||||
|
|
||||||
before_install:
|
before_install:
|
||||||
- yarn global add wait-on
|
- yarn global add wait-on
|
||||||
|
# Install Codecov
|
||||||
|
- yarn global add codecov
|
||||||
- yarn install
|
- yarn install
|
||||||
- cp cypress.env.template.json cypress.env.json
|
- cp cypress.env.template.json cypress.env.json
|
||||||
|
|
||||||
@ -18,6 +20,7 @@ install:
|
|||||||
- wait-on http://localhost:7474 && docker-compose exec neo4j migrate
|
- wait-on http://localhost:7474 && docker-compose exec neo4j migrate
|
||||||
|
|
||||||
script:
|
script:
|
||||||
|
# Backend
|
||||||
- docker-compose exec backend yarn run lint
|
- docker-compose exec backend yarn run lint
|
||||||
- docker-compose exec backend yarn run test:jest --ci --verbose=false
|
- docker-compose exec backend yarn run test:jest --ci --verbose=false
|
||||||
- docker-compose exec backend yarn run db:reset
|
- docker-compose exec backend yarn run db:reset
|
||||||
@ -25,10 +28,14 @@ script:
|
|||||||
- docker-compose exec backend yarn run test:cucumber
|
- docker-compose exec backend yarn run test:cucumber
|
||||||
- docker-compose exec backend yarn run db:reset
|
- docker-compose exec backend yarn run db:reset
|
||||||
- docker-compose exec backend yarn run db:seed
|
- docker-compose exec backend yarn run db:seed
|
||||||
|
# Frontend
|
||||||
- docker-compose exec webapp yarn run lint
|
- docker-compose exec webapp yarn run lint
|
||||||
- docker-compose exec webapp yarn run test --ci --verbose=false
|
- docker-compose exec webapp yarn run test --ci --verbose=false
|
||||||
- docker-compose exec -d backend yarn run test:before:seeder
|
- docker-compose exec -d backend yarn run test:before:seeder
|
||||||
|
# Fullstack
|
||||||
- CYPRESS_RETRIES=1 yarn run cypress:run
|
- CYPRESS_RETRIES=1 yarn run cypress:run
|
||||||
|
# Coverage
|
||||||
|
- codecov
|
||||||
|
|
||||||
after_success:
|
after_success:
|
||||||
- wget https://raw.githubusercontent.com/DiscordHooks/travis-ci-discord-webhook/master/send.sh
|
- wget https://raw.githubusercontent.com/DiscordHooks/travis-ci-discord-webhook/master/send.sh
|
||||||
|
|||||||
@ -11,6 +11,9 @@ services:
|
|||||||
build:
|
build:
|
||||||
context: webapp
|
context: webapp
|
||||||
target: build-and-test
|
target: build-and-test
|
||||||
|
volumes:
|
||||||
|
#/nitro-web
|
||||||
|
- ./webapp/coverage:/nitro-web/coverage
|
||||||
environment:
|
environment:
|
||||||
- GRAPHQL_URI=http://backend:4000
|
- GRAPHQL_URI=http://backend:4000
|
||||||
backend:
|
backend:
|
||||||
@ -18,6 +21,8 @@ services:
|
|||||||
build:
|
build:
|
||||||
context: backend
|
context: backend
|
||||||
target: builder
|
target: builder
|
||||||
|
volumes:
|
||||||
|
- ./backend/coverage:/nitro-backend/coverage
|
||||||
ports:
|
ports:
|
||||||
- 4001:4001
|
- 4001:4001
|
||||||
- 4123:4123
|
- 4123:4123
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user