Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
git2
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
git2
Commits
429c7f11
Commit
429c7f11
authored
Sep 17, 2018
by
Edward Thomson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ci: don't stop on failure
Don't stop on test failures; run all the tests, even when a test fails.
parent
7c9769d9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
8 deletions
+17
-8
ci/test.ps1
+4
-1
ci/test.sh
+13
-7
No files found.
ci/test.ps1
View file @
429c7f11
...
@@ -7,6 +7,7 @@ $PSDefaultParameterValues['*:ErrorAction'] = 'Stop'
...
@@ -7,6 +7,7 @@ $PSDefaultParameterValues['*:ErrorAction'] = 'Stop'
$SourceDir
=
Split-Path
(
Split-Path
(
Get-Variable
MyInvocation
)
.Value.MyCommand.Path
)
$SourceDir
=
Split-Path
(
Split-Path
(
Get-Variable
MyInvocation
)
.Value.MyCommand.Path
)
$BuildDir
=
Get-Location
$BuildDir
=
Get-Location
$Success
=
$true
if
(
$Env
:SKIP_TESTS
)
{
exit
}
if
(
$Env
:SKIP_TESTS
)
{
exit
}
...
@@ -24,7 +25,7 @@ function run_test {
...
@@ -24,7 +25,7 @@ function run_test {
Write-Host
$TestCommand
Write-Host
$TestCommand
Invoke-Expression
$TestCommand
Invoke-Expression
$TestCommand
if
(
$LastExitCode
-ne 0
)
{
[
Environment]::Exit
(
$LastExitCode
)
}
if
(
$LastExitCode
-ne 0
)
{
$Success
=
$false
}
}
}
Write-Host
"##############################################################################"
Write-Host
"##############################################################################"
...
@@ -67,3 +68,5 @@ if (-not $Env:SKIP_PROXY_TESTS) {
...
@@ -67,3 +68,5 @@ if (-not $Env:SKIP_PROXY_TESTS) {
taskkill /F /IM javaw.exe
taskkill /F /IM javaw.exe
}
}
if
(
-not
$Success
)
{
exit
1
}
ci/test.sh
View file @
429c7f11
...
@@ -11,6 +11,8 @@ BUILD_DIR=$(pwd)
...
@@ -11,6 +11,8 @@ BUILD_DIR=$(pwd)
TMPDIR
=
${
TMPDIR
:-
/tmp
}
TMPDIR
=
${
TMPDIR
:-
/tmp
}
USER
=
${
USER
:-$(
whoami
)}
USER
=
${
USER
:-$(
whoami
)}
SUCCESS
=
1
VALGRIND
=
"valgrind --leak-check=full --show-reachable=yes --error-exitcode=125 --num-callers=50 --suppressions=
\"
$SOURCE_DIR
/libgit2_clar.supp
\"
"
VALGRIND
=
"valgrind --leak-check=full --show-reachable=yes --error-exitcode=125 --num-callers=50 --suppressions=
\"
$SOURCE_DIR
/libgit2_clar.supp
\"
"
LEAKS
=
"MallocStackLogging=1 MallocScribble=1 leaks -quiet -atExit -- nohup"
LEAKS
=
"MallocStackLogging=1 MallocScribble=1 leaks -quiet -atExit -- nohup"
...
@@ -30,11 +32,9 @@ cleanup() {
...
@@ -30,11 +32,9 @@ cleanup() {
echo
"Done."
echo
"Done."
}
}
di
e
()
{
failur
e
()
{
echo
"Test exited with code:
$1
"
echo
"Test exited with code:
$1
"
SUCCESS
=
0
cleanup
exit
$1
}
}
# Ask ctest what it would run if we were to invoke it directly. This lets
# Ask ctest what it would run if we were to invoke it directly. This lets
...
@@ -54,7 +54,7 @@ run_test() {
...
@@ -54,7 +54,7 @@ run_test() {
RUNNER
=
"
$TEST_CMD
"
RUNNER
=
"
$TEST_CMD
"
fi
fi
eval
$RUNNER
||
die
$?
eval
$RUNNER
||
failure
}
}
# Configure the test environment; run them early so that we're certain
# Configure the test environment; run them early so that we're certain
...
@@ -194,10 +194,16 @@ if [ -z "$SKIP_FUZZERS" ]; then
...
@@ -194,10 +194,16 @@ if [ -z "$SKIP_FUZZERS" ]; then
echo
"##############################################################################"
echo
"##############################################################################"
for
fuzzer
in
fuzzers/
*
_fuzzer
;
do
for
fuzzer
in
fuzzers/
*
_fuzzer
;
do
"
${
fuzzer
}
"
"
${
SOURCE_DIR
}
/fuzzers/corpora/
$(
basename
"
${
fuzzer
%_fuzzer
}
"
)
"
||
die
$?
"
${
fuzzer
}
"
"
${
SOURCE_DIR
}
/fuzzers/corpora/
$(
basename
"
${
fuzzer
%_fuzzer
}
"
)
"
||
failure
done
done
fi
fi
echo
"Success."
cleanup
cleanup
if
[
"
$SUCCESS
"
-ne
"1"
]
;
then
echo
"Some tests failed."
exit
1
fi
echo
"Success."
exit
0
exit
0
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment