Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit ba9bb66

Browse files
committed
tests: create a ctest target for cred_callback
1 parent a4cba9d commit ba9bb66

File tree

3 files changed

+8
-4
lines changed

3 files changed

+8
-4
lines changed

CMakeLists.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -682,6 +682,10 @@ IF (BUILD_CLAR)
682682
ELSE ()
683683
ADD_TEST(libgit2_clar libgit2_clar -v)
684684
ENDIF ()
685+
686+
# Add a test target which runs the cred callback tests, to be
687+
# called after setting the url and user
688+
ADD_TEST(libgit2_clar-cred_callback libgit2_clar -v -sonline::clone::cred_callback)
685689
ENDIF ()
686690

687691
IF (TAGS)

appveyor.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ build_script:
3737
if "%GENERATOR%"=="MSYS Makefiles" (C:\MinGW\msys\1.0\bin\sh --login /c/projects/libgit2/script/appveyor-mingw.sh)
3838
test_script:
3939
- ps: |
40-
ctest -V .
40+
ctest -V -R libgit2_clar
4141
$env:GITTEST_REMOTE_URL="https://github.com/libgit2/non-existent"
4242
$env:GITTEST_REMOTE_USER="libgit2test"
43-
.\Debug\libgit2_clar -sonline::clone::cred_callback
43+
ctest -V -R libgit2_clar-cred_callback

script/cibuild.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ git daemon --listen=localhost --export-all --enable=receive-pack --base-path="$H
2525
export GITTEST_REMOTE_URL="git://localhost/test.git"
2626

2727
# Run the test suite
28-
ctest -V . || exit $?
28+
ctest -V -R libgit2_clar || exit $?
2929

3030
# Now that we've tested the raw git protocol, let's set up ssh to we
3131
# can do the push tests over it
@@ -59,4 +59,4 @@ fi
5959

6060
export GITTEST_REMOTE_URL="https://github.com/libgit2/non-existent"
6161
export GITTEST_REMOTE_USER="libgit2test"
62-
./libgit2_clar -sonline::clone::cred_callback || exit $?
62+
ctest -V -R libgit2_clar-cred_callback

0 commit comments

Comments
 (0)