-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Ivo Bellin Salarin
committed
Feb 3, 2020
1 parent
6e23460
commit ed8960c
Showing
14 changed files
with
156 additions
and
28 deletions.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,3 +11,4 @@ cc.html | |
diff.html | ||
ccguard.db | ||
venv | ||
notes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
from ccguard.ccguard import ( | ||
SqliteAdapter, | ||
ReferenceAdapter, | ||
configuration, | ||
GitAdapter, | ||
adapter_factory, | ||
) | ||
from ccguard import redis_adapter, ccguard_sync, web_adapter |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# documentation: how to setup ccguard for CI | ||
|
||
## launch the server | ||
|
||
the aim of the server is to centralize the code coverage data for the whole team, and to ensure that it has not regressed. | ||
|
||
on a machine accessible via internet | ||
|
||
```sh | ||
pip install ccguard | ||
# for more safety, change the port anc the token | ||
ccguard_server --port 17132 --token EyNHvrWsP6BiiS3QrmzoY3NQNmHLMeYD7SVfAVYK | ||
``` | ||
|
||
## circleci | ||
|
||
expose environment variables | ||
|
||
```sh | ||
CCGUARD_SERVER_ADDRESS=http://ccguard_server:17132 | ||
CCGUARD_TOKEN=EyNHvrWsP6BiiS3QrmzoY3NQNmHLMeYD7SVfAVYK | ||
``` | ||
|
||
add to your circleci.yaml | ||
|
||
```sh | ||
ccguard --adapter web coverage.xml | ||
``` | ||
|
||
## on every team member host | ||
|
||
you can retrieve the data collected by ccguard, periodically, with the command | ||
|
||
```sh | ||
CCGUARD_SERVER_ADDRESS=http://ccguard_server:17132 | ||
# no token required to retrieve the coverage data | ||
# retrieve the data (requires ccguard 0.4) | ||
ccguard_sync web sqlite | ||
# inspect the log (directly in the repository you want to check) | ||
ccguard_log | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
rm dist/*.whl | ||
rm -rf /tmp/venv | ||
python3 setup.py bdist_wheel | ||
python3 -m venv /tmp/venv | ||
source /tmp/venv/bin/activate | ||
cd /tmp/ | ||
python3 -m pip install /Users/ivo/dev/ccguard/dist/*.whl | ||
|
||
#git clone https://github.com/nilleb/fsevents-watcher | ||
#cd fsevents-watcher | ||
exit | ||
|
||
# the test scenario follows | ||
source /tmp/venv/bin/activate | ||
ccguard_server --token aaaa --port 8888 | ||
|
||
source /tmp/venv/bin/activate | ||
export ccguard_server_address=http://localhost:8888 | ||
export ccguard_token=aaaa | ||
cd ~/dev/rav1e | ||
ccguard --adapter web coverage.xml | ||
ccguard_log | ||
ccguard_sync |