Skip to content

Commit

Permalink
codecov for python
Browse files Browse the repository at this point in the history
  • Loading branch information
moazreyad authored and Moaz Reyad committed Sep 5, 2020
1 parent 7586a3b commit 18c2af6
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 4 deletions.
19 changes: 19 additions & 0 deletions .codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

ignore:
- proto/*
2 changes: 2 additions & 0 deletions .github/workflows/conda.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,5 @@ jobs:
run: conda config --add channels conda-forge && conda config --add channels nusdbsystem
- name: build-pytest
run: conda build tool/conda/singa
env:
TEST_COMMAND: pytest --cov=$PREFIX/lib/python3.7/site-packages/singa --cov-report=xml && codecov --flags singa-python
2 changes: 2 additions & 0 deletions .github/workflows/ubuntu.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -60,3 +60,5 @@ jobs:
run: build/bin/test_singa
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
with:
flags: singa-cpp
10 changes: 6 additions & 4 deletions tool/conda/singa/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -75,14 +75,16 @@ requirements:
- tqdm
- onnx 1.6.0
- deprecated 1.2.7
- pytest


test:
requires:
- pytest-cov
- tabulate
- codecov
source_files:
- test/python/*.py
commands:
- cd test/python && python run.py

- {{ environ.get('TEST_COMMAND', 'cd test/python && python run.py') }}
about:
home: http://singa.apache.org/
license: Apache V2
Expand Down

0 comments on commit 18c2af6

Please sign in to comment.