diff options
| author | Kevin Koch <kpkoch@mit.edu> | 2008-02-29 19:08:06 +0000 |
|---|---|---|
| committer | Kevin Koch <kpkoch@mit.edu> | 2008-02-29 19:08:06 +0000 |
| commit | 55dbf9d7dadf1783665f56b296d7e633afdc6ef1 (patch) | |
| tree | efb2c15ed32b5bc24338f1c053767eaea9e7ae61 /src/ccapi/test | |
| parent | b302584b340be1089e5191b0e9912124bbe65962 (diff) | |
| download | krb5-55dbf9d7dadf1783665f56b296d7e633afdc6ef1.tar.gz krb5-55dbf9d7dadf1783665f56b296d7e633afdc6ef1.tar.xz krb5-55dbf9d7dadf1783665f56b296d7e633afdc6ef1.zip | |
lib/win/Makefile.in: Added
ccutils.c, ccapi_os_ipc.cxx, ccs_reply_proc.c, ccs_os_server.cpp, ccs_reply_proc.c, ccs_win_pipe.c: comment out some debug messages.
test/Makefile.in: change which tests are built.
test/test_ccapi_context.c: API version 2 is now expected to pass.
test/test_ccapi_iterators.c: Add progress indicator for long tests.
TargetVersion: 1.7
Component: krb5-libs
Ticket: 5594
Tags: pullup
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@20244 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/ccapi/test')
| -rw-r--r-- | src/ccapi/test/Makefile.in | 25 | ||||
| -rw-r--r-- | src/ccapi/test/test_ccapi_context.c | 2 | ||||
| -rw-r--r-- | src/ccapi/test/test_ccapi_iterators.c | 7 |
3 files changed, 23 insertions, 11 deletions
diff --git a/src/ccapi/test/Makefile.in b/src/ccapi/test/Makefile.in index c5a5ad718..e5238c2c7 100644 --- a/src/ccapi/test/Makefile.in +++ b/src/ccapi/test/Makefile.in @@ -47,9 +47,14 @@ PINGOBJS = $(OUTPRE)ccs_request_c.$(OBJEXT) \ $(OUTPRE)pingtest.$(OBJEXT) \ $(OBJECTS) -TEST_NAMES = test_constants \ +TESTALLOBJS=$(OUTPRE)main.$(OBJEXT) \ + $(OBJECTS) + +TEST_NAMES = test_cc_ccache_iterator_next \ + test_constants \ test_cc_initialize \ - test_cc_context_get_version + test_cc_context_get_version \ + test_cc_credentials_iterator_next MORE_TESTS = test_cc_context_release \ test_cc_context_get_change_time \ @@ -77,9 +82,7 @@ MORE_TESTS = test_cc_context_release \ test_cc_ccache_compare \ test_cc_ccache_get_kdc_time_offset \ test_cc_ccache_set_kdc_time_offset \ - test_cc_ccache_clear_kdc_time_offset \ - test_cc_ccache_iterator_next \ - test_cc_credentials_iterator_next + test_cc_ccache_clear_kdc_time_offset ##### Linker LINK = link @@ -87,8 +90,8 @@ LIBS = -lkrb5 ##DOS##LIBS = advapi32.lib rpcrt4.lib user32.lib ws2_32.lib ccapi.lib LFLAGS = /nologo $(LOPTS) -all-mac:: setup-test-dir pingtest stop_here simple_lock_test build-base build-tests link-tests copy-script success-message -all-windows:: setup-windows build-base $(OUTPRE)pingtest.exe build-tests copy-script success-message +all-mac:: setup-test-dir pingtest simple_lock_test build-base build-tests link-tests copy-script success-message +all-windows:: setup-windows build-base $(OUTPRE)pingtest.exe build-tests build-testall copy-script success-message # compile base files used by all tests build-base: $(PINGOBJS) @@ -125,7 +128,7 @@ $(WINH): copy ..\lib\win\srctmp\$@ . # This rule assumes that nmake in ..\lib\win\ has already run. -$(OUTPRE)pingtest.exe: $(OBJECTS) +$(OUTPRE)pingtest.exe: $(OBJECTS) $(PINGOBJS) # There doesn't appear to be any way to examine a variable and return a value # indicating whether a string is present in it. We use a perl script to # check the LIB variable. If the path to ccapi.lib isn't present, the script @@ -141,6 +144,12 @@ $(OUTPRE)pingtest.exe: $(OBJECTS) link-tests: $(TEST_NAMES) +build-testall: $(TEST_NAMES) $(OBJECTS) $(TESTALLOBJS) testall.exe + +testall.exe: + $(LINK) $(linkdebug) /map:$(@B)1.map -out:$(*B)1.exe $(conflags) $(TESTALLOBJS) $(LIBS) $(conslibdll) + + simple_lock_test: $(CC) -o $(TESTDIR)/simple_lock_test simple_lock_test.c $(LIBS) diff --git a/src/ccapi/test/test_ccapi_context.c b/src/ccapi/test/test_ccapi_context.c index c3f6d6e0d..ad437de58 100644 --- a/src/ccapi/test/test_ccapi_context.c +++ b/src/ccapi/test/test_ccapi_context.c @@ -11,7 +11,7 @@ int check_cc_initialize() { BEGIN_TEST("cc_initialize"); // try every api_version - err = check_once_cc_initialize(&context, ccapi_version_2, NULL, NULL, 9, "cc_initialize with ccapi_version_2"); // err == CC_BAD_API_VERSION (9) would be imported by CredentialsCache2.h + err = check_once_cc_initialize(&context, ccapi_version_2, NULL, NULL, ccNoError, "cc_initialize with ccapi_version_2"); // err == CC_BAD_API_VERSION (9) would be imported by CredentialsCache2.h err = check_once_cc_initialize(&context, ccapi_version_3, NULL, NULL, ccNoError, "cc_initialize with ccapi_version_3"); // !err err = check_once_cc_initialize(&context, ccapi_version_4, NULL, NULL, ccNoError, "cc_initialize with ccapi_version_4"); // " err = check_once_cc_initialize(&context, ccapi_version_5, NULL, NULL, ccNoError, "cc_initialize with ccapi_version_5"); // " diff --git a/src/ccapi/test/test_ccapi_iterators.c b/src/ccapi/test/test_ccapi_iterators.c index e15c7deb2..42a4f97c4 100644 --- a/src/ccapi/test/test_ccapi_iterators.c +++ b/src/ccapi/test/test_ccapi_iterators.c @@ -2,6 +2,7 @@ #include "test_ccapi_iterators.h" #include "test_ccapi_check.h" #include "test_ccapi_util.h" +#include "cci_debugging.h" // --------------------------------------------------------------------------- @@ -55,7 +56,8 @@ int check_cc_ccache_iterator_next() { } for(i = 0; !err && (i < 1000); i++) { - err = cc_context_create_new_ccache(context, cc_credentials_v5, "foo@BAR.ORG", &ccache); + if (i%10 == 0) cci_debug_printf("%s loop: %d", __FUNCTION__, i); + err = cc_context_create_new_ccache(context, cc_credentials_v5, "foo@BAR.ORG", &ccache); if (ccache) { cc_ccache_release(ccache); ccache = NULL; @@ -186,7 +188,8 @@ int check_cc_credentials_iterator_next() { err = cc_context_create_new_ccache(context, cc_credentials_v5, "foo@BAR.ORG", &ccache); } for(i = 0; !err && (i < 1000); i++) { - new_v5_creds_union(&creds_union, "BAR.ORG"); + if (i%10 == 0) cci_debug_printf("%s loop: %d", __FUNCTION__, i); + new_v5_creds_union(&creds_union, "BAR.ORG"); err = cc_ccache_store_credentials(ccache, &creds_union); release_v5_creds_union(&creds_union); } |
