From 6089a0b78220a163dd4a2c7fe0f5447933391475 Mon Sep 17 00:00:00 2001 From: Ken Raeburn Date: Mon, 28 Dec 2009 00:21:06 +0000 Subject: [PATCH] allow testing when offline Define new make variable OFFLINE to "no"; if it's set to "yes", skip the testing of t_locate_kdc, which requires access to mit.edu SRV records. ticket: 6606 git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@23520 dc483132-0cff-0310-8789-dd5450dbe970 --- src/config/pre.in | 7 +++++++ src/lib/krb5/os/Makefile.in | 6 +++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/src/config/pre.in b/src/config/pre.in index 34bb7522d..5cfb5546d 100644 --- a/src/config/pre.in +++ b/src/config/pre.in @@ -564,6 +564,13 @@ VALGRIND= VALGRIND_LOGDIR = `cd $(BUILDTOP)&&pwd` VALGRIND1 = valgrind --tool=memcheck --log-file=$(VALGRIND_LOGDIR)/vg --trace-children=yes -v --leak-check=yes --suppressions=`cd $(top_srcdir)&&pwd`/util/valgrind-suppressions +# Set OFFLINE=yes to disable tests that assume network connectivity. +# (Specifically, this concerns the ability to fetch DNS data for +# mit.edu, to verify that SRV queries are working.) Note that other +# tests still assume that the local hostname can be resolved into +# something that looks like an FQDN, with an IPv4 address. +OFFLINE=no + ## ## end of pre.in ############################################################ diff --git a/src/lib/krb5/os/Makefile.in b/src/lib/krb5/os/Makefile.in index 8788c897a..215d39014 100644 --- a/src/lib/krb5/os/Makefile.in +++ b/src/lib/krb5/os/Makefile.in @@ -201,7 +201,11 @@ check-unix:: $(TEST_PROGS) cmp test.out $(srcdir)/ref_std_conf.out $(RM) test.out KRB5_CONFIG=$(srcdir)/td_krb5.conf ; export KRB5_CONFIG ;\ - $(KRB5_RUN_ENV) $(VALGRIND) ./t_locate_kdc ATHENA.MIT.EDU + if test "$(OFFLINE)" != yes; then \ + $(KRB5_RUN_ENV) $(VALGRIND) ./t_locate_kdc ATHENA.MIT.EDU; \ + else \ + echo SKIPPING t_locate_kdc TEST WHILE OFFLINE; \ + fi # # Do some aname-to-lname testing. -- 2.26.2