Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ENH: Attempt to cover external remotes execution -- might get too muc…
…h :-/
- Loading branch information
1 parent
a9c6915
commit f80fc69
Showing
5 changed files
with
42 additions
and
0 deletions.
There are no files selected for viewing
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,4 @@ | ||
[paths] | ||
source = | ||
datalad/ | ||
*/datalad/ |
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,31 @@ | ||
#!/bin/bash | ||
# | ||
# A little helper to overload default datalad executables with the one ran | ||
# through coverage | ||
|
||
set -eu | ||
|
||
bin=$(basename $0) | ||
curbin=$(which "$bin") | ||
curdatalad=$(which datalad) | ||
curdir=$(dirname $curdatalad) | ||
|
||
|
||
COVERAGE=${COVERAGE:-python-coverage} | ||
COVERAGE_RUN="`which $COVERAGE` run" | ||
|
||
export PATH=${PATH//$curdir:/} | ||
newdatalad=$(which datalad) | ||
newbin=$(which $bin) | ||
newpython=$(sed -ne '1s/#!//gp' $newdatalad) | ||
|
||
if [ $newdatalad = $curdatalad ]; then | ||
echo "E: binary remained the same: $newdatalad" >&2 | ||
exit 1 | ||
fi | ||
|
||
touch /tmp/coverages | ||
export COVERAGE_FILE=/tmp/.coverage-entrypoints-$RANDOM | ||
echo "Running now $newpython $COVERAGE_RUN --include=datalad/* -a $newbin $@" >> /tmp/coverages | ||
#$newpython $COVERAGE_RUN --include=datalad/* -a $newbin "$@" | ||
$newpython $COVERAGE_RUN -a $newbin "$@" |
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 @@ | ||
datalad |
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 @@ | ||
datalad |