From 380fc251f440f42485170ee9dbff239fa3e1550b Mon Sep 17 00:00:00 2001 From: FengZiYjun Date: Sat, 11 Aug 2018 10:11:09 +0800 Subject: [PATCH] add code coverage --- .travis.yml | 13 +++++++++++++ README.md | 2 ++ 2 files changed, 15 insertions(+) create mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 00000000..077bd1c4 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,13 @@ +language: python +python: + - "3.6" +# command to install dependencies +install: + - pip install --quiet -r requirements.txt + - pip install pytest pytest-cov +# command to run tests +script: + - pytest --cov=./ + +after_success: + - codecov \ No newline at end of file diff --git a/README.md b/README.md index 71357775..4068febc 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,6 @@ # FastNLP +[![Build Status](https://travis-ci.org/fastnlp/fastNLP.svg?branch=master)](https://travis-ci.org/fastnlp/fastNLP) +[![codecov](https://codecov.io/gh/fastnlp/fastNLP/branch/master/graph/badge.svg)](https://codecov.io/gh/fastnlp/fastNLP) ``` FastNLP ├── docs