Commit Graph

7376 Commits

Author SHA1 Message Date
Ondřej Surý
a5ea870265 Add __attribute__ ((fallthrough)); in place of implicit fallthrough to satisfy gcc 7 -Wextra 2018-03-15 09:30:18 +01:00
Ondřej Surý
9f830be501 update file headers to remove copyright years 2018-03-15 09:09:15 +01:00
Evan Hunt
a6e5d9a2ca Merge branch 'clean-bin-tests-v9_9' into 'v9_9'
clean up bin/tests, convert unit tests to ATF

Closes #115

See merge request isc-projects/bind9!93
2018-03-09 23:52:26 -08:00
Evan Hunt
e6c446bfba final cleanup
- update Kyuafiles to match Atffiles
- copyrights
- CHANGES note

(cherry picked from commit 86e00cbb71)
(cherry picked from commit 80834b5b90)
(cherry picked from commit 442c1530a3)
(cherry picked from commit 6fe8188cc3)
2018-03-09 23:35:02 -08:00
Evan Hunt
40d0aab21a reduce race risk in parallel builds
(cherry picked from commit 74347f4a55)
(cherry picked from commit 7f4e62d902)
(cherry picked from commit ade4face27)
(cherry picked from commit 544bb12a01)
2018-03-09 23:24:17 -08:00
Evan Hunt
2591c077f0 migrate t_dst signature test to lib/dns/tests/dst_test
(cherry picked from commit a4ebe83cdb)
(cherry picked from commit 4439c471d1)
(cherry picked from commit 57a5820dcc)
(cherry picked from commit dbc21e4393)
2018-03-09 23:22:04 -08:00
Evan Hunt
a11252dbbc migrate t_db to lib/dns/tests/db_test
(cherry picked from commit f58ac8ada3)
(cherry picked from commit 56da937399)
(cherry picked from commit d3518e57b1)
(cherry picked from commit c5dbc0b727)
2018-03-09 23:20:11 -08:00
Evan Hunt
28d62b0a31 migrate t_names to lib/dns/tests/name_test
(cherry picked from commit 8ecf69ef7b)
(cherry picked from commit aefad99e1e)
(cherry picked from commit b2fef3b438)
(cherry picked from commit 2893e982ed)
2018-03-09 23:19:11 -08:00
Evan Hunt
20da3cd7e7 migrate t_rbt to lib/dns/tests/rbt_test
(cherry picked from commit 109546cbda)
(cherry picked from commit c505afd183)
(cherry picked from commit 42fa3932ab)
(cherry picked from commit 4c6818ff8e)
2018-03-09 23:17:36 -08:00
Evan Hunt
a73b843515 migrate t_tasks to lib/isc/tests/task_test
(cherry picked from commit c6c1e99252)
(cherry picked from commit 88bfe56876)
(cherry picked from commit 38f9cddcad)
(cherry picked from commit 430d35e332)
2018-03-09 23:15:10 -08:00
Evan Hunt
48c8aca49b migrate t_resolver to lib/dns/tests/resolver_test
(cherry picked from commit d80825c40b)
(cherry picked from commit 30e157f6e4)
(cherry picked from commit 5dd25f2285)
(cherry picked from commit 29474940ea)
2018-03-09 23:13:44 -08:00
Evan Hunt
6bd3de3615 migrate t_timers to lib/isc/tests/timer_test
(cherry picked from commit e2b8699df9)
(cherry picked from commit efccdad0ea)
(cherry picked from commit 274ee0b425)
(cherry picked from commit 5b477b2aa4)
2018-03-09 23:11:47 -08:00
Evan Hunt
a6dcb138b5 migrate t_atomic to lib/isc/tests/atomic_test
(cherry picked from commit 874e2fc70c)
(cherry picked from commit c7fa56e8db)
(cherry picked from commit 492e19d6ec)
(cherry picked from commit 1200d6f072)
2018-03-09 23:09:54 -08:00
Evan Hunt
d446bbb815 migrate t_mem to lib/isc/tests/mem_test
(cherry picked from commit 979f054702)
(cherry picked from commit af48544b75)
(cherry picked from commit 814cd21e22)
(cherry picked from commit 7014d0994b)
2018-03-09 23:07:40 -08:00
Evan Hunt
00bc2c2355 migrate t_net to lib/isc/tests
(cherry picked from commit 05b7251d51)
(cherry picked from commit af0c9b2cee)
(cherry picked from commit faedafd2b4)
(cherry picked from commit 67b63a3e10)
2018-03-09 23:03:56 -08:00
Evan Hunt
6b970316c8 migrate t_sockaddr to lib/isc/tests
(cherry picked from commit 62f650078a)
(cherry picked from commit fadb93cf43)
(cherry picked from commit 323e2f7152)
(cherry picked from commit b392c18f6e)
2018-03-09 23:03:11 -08:00
Evan Hunt
e54d53e8fb remove hashes test (duplicates lib/isc/tests/hash_test)
(cherry picked from commit 6ad1a042bc)
(cherry picked from commit e686b9c297)
(cherry picked from commit c644427b77)
(cherry picked from commit a0a3a8e794)
2018-03-09 23:01:44 -08:00
Evan Hunt
d50b40b135 remove master test (duplicates lib/isc/tests/master_test)
(cherry picked from commit 6717f31e10)
(cherry picked from commit 36d08442bc)
(cherry picked from commit ae39f25a10)
(cherry picked from commit 83a5d8e17e)
2018-03-09 23:00:47 -08:00
Evan Hunt
bf769f68a4 migrate tests from bin/tests/dnssec-signzone to bin/tests/system/dnssec
- added tests to the dnssec system test that duplicate the ones
  from bin/tests/dnssec-signzone
- changed cleanall.sh so it doesn't automatically remove all
  key files, because there are now some of those that are part of the
  distribution

(cherry picked from commit ccfe778c01)
(cherry picked from commit d8f8eee381)
(cherry picked from commit dbb225d83e)
(cherry picked from commit 161f525942)
2018-03-09 22:59:52 -08:00
Evan Hunt
bb2b5193b5 move all optional tests from bin/tests to bin/tests/optional
- some of these tests are obsolete and should be cleared up,
  others overlap with ATF tests and may be removed later.
  for now, let's just tidy up the bin/tests directory by
  moving these files down a level.

(cherry picked from commit 344ab0eb7d)
(cherry picked from commit dafdf2c09b)
(cherry picked from commit e062109659)
(cherry picked from commit 6428478341)
2018-03-09 22:59:24 -08:00
Evan Hunt
fca5c351c2 remove some old and obsolete test files
(cherry picked from commit a633f6c5dd)
(cherry picked from commit 10efb4ff07)
(cherry picked from commit 22d9a69b3f)
(cherry picked from commit b7c98c81d9)
2018-03-09 22:56:04 -08:00
Ondřej Surý
5e88bf24f7 Update documentation to remove obsolete bind9-bugs@isc.org email address
(cherry picked from commit efc9bc5d8d)
(cherry picked from commit 486e79050f)
(cherry picked from commit 292d6c8a5b)
2018-03-08 10:42:40 -08:00
Evan Hunt
e44ce6a1ab restore long options for run.sh
(cherry picked from commit 4a714bffbc)
2018-03-07 14:35:45 -08:00
Evan Hunt
ac91515aa8 eliminate unnecessary waiting in allow-query test
- grep in the log to see if configuration is finished rather
  than sleeping for 5 seconds

(cherry picked from commit a9b6bed6af)
(cherry picked from commit 37a6bb004c)
(cherry picked from commit 2e48caa476)
2018-03-07 14:19:55 -08:00
Evan Hunt
0ed2df43b0 rename allow_query to allow-query
(cherry picked from commit ffc3e73c36)
(cherry picked from commit 5d9e3f9b02)
(cherry picked from commit de6fe7dd83)
2018-03-07 14:19:52 -08:00
Evan Hunt
fc1b254b5e address a possible notify test failure
- wait for the transfer completion message to apear in the log instead
  of the notify message. this ensures we don't check for the presense of
  transfered records during the time between the notify and the
  transfer.

(cherry picked from commit ad32553c1d)
(cherry picked from commit dff94add3e)
(cherry picked from commit 5a5e476d00)
2018-03-06 11:48:16 -08:00
Evan Hunt
8c0d2127f9 revise soft limit test
- don't bail out of the loop if clients are exceeded, just count incidents
- verbosely describe expectations and results

(cherry picked from commit 86838b2a02)
2018-03-01 15:41:01 +01:00
Mark Andrews
a845283012 remove unsupported command line argument (-4) from nsupdate call
(cherry picked from commit ac3d2a0ed9)
2018-03-01 13:56:16 +01:00
Mark Andrews
83990e9bdc wait for 'all zones loaded' rather than 'reloading zones succeeded' which just indicates that everything kicked off ok
(cherry picked from commit 4cb0873a0a)
2018-02-28 14:57:19 +01:00
Evan Hunt
be98afaecf Do not destroy systests.output if there are no test.output files
(cherry picked from commit 38940619c6)
2018-02-27 10:04:37 -08:00
Michał Kępień
d241bf9d4c Use echoinfo for printing test summary
This ensures testsummary.sh is consistent with other scripts belonging
to the test framework.

(cherry picked from commit 642e20db8a)
2018-02-27 10:04:37 -08:00
Michał Kępień
b18292a208 Make testsummary.sh print a list of failed system tests
Print a list of failed system tests, if any, below the system test
summary to avoid the need to manually search through the test log.

(cherry picked from commit 28068857e7)
2018-02-27 10:04:36 -08:00
Michał Kępień
1709486103 Tweak the regular expression used for extracting system test results
The current regular expression used for extracting system test results
from systests.output, "^R:", is anchored at the start of a line, which
prevents colored system test output from being properly processed.  As
just "R:" would arguably be too general, extend the pattern a bit to
ensure it will only match lines containing system test results.

(cherry picked from commit 9006d6dbbd)
2018-02-27 10:04:36 -08:00
Evan Hunt
92c9e7c045 clean up test output
- removed a few remaing places where output wasn't being passed
  through echo_i or cat_i
- added a "digcomp" function to conf.sh.in to send digcomp.pl output
  through cat_i and return the correct exit value
- set SYSTESTDIR when calling echo_i from nsX directories, so that
  the test name will always be printed correctly
- fixed a test name typo in conf.sh.in

(cherry picked from commit 0e52fbd0b3)
(cherry picked from commit d57e8f6df3)
(cherry picked from commit 053c06d5e1)
2018-02-27 10:03:21 -08:00
Evan Hunt
4cb037a6e2 Merge branch '112-fix-mx-checks-for-dynamic-updates-v9_9' into 'v9_9'
Fix MX checks for dynamic updates

Closes #112

See merge request isc-projects/bind9!79
2018-02-26 15:20:49 -08:00
Michał Kępień
d86a7dbe69 Fix MX checks for dynamic updates
The check_mx() function in lib/ns/update.c incorrectly tests whether the
DNS_RDATA_CHECKMX/DNS_RDATA_CHECKMXFAIL flags are set for each applied
MX record update as these flags are never set in code paths related to
dynamic updates; they can only be set when loading a zone from a master
file (DNS_ZONEOPT_CHECKMX -> DNS_MASTER_CHECKMX -> DNS_RDATA_CHECKMX).
This flaw allows MX records containing IP addresses to be added to a
zone even when "check-mx fail;" is used.

Ensure correct behavior by modifying the relevant tests in check_mx() so
that they use DNS_ZONEOPT_CHECKMX/DNS_ZONEOPT_CHECKMXFAIL instead.

(cherry picked from commit 857a40c87b)
2018-02-26 15:20:06 -08:00
Evan Hunt
cdf3f823bb Merge branch 'check-for-test-interfaces-before-running-system-tests-v9_9' into 'v9_9'
Check for test interfaces before running system tests

See merge request isc-projects/bind9!19
2018-02-26 15:10:40 -08:00
Evan Hunt
699fffc34f test interfaces directly in runall.sh and parallel.mk
(cherry picked from commit a8b583e78b)
2018-02-26 15:10:40 -08:00
Michał Kępień
98b3b5bba7 Check for test interfaces before running system tests
Prevent runall.sh and "make test" from even attempting to run system
tests when "ifconfig.sh up" has not been run beforehand.  This ensures
the user is not flooded with error messages in such a case.

(cherry picked from commit e0221f2d25)
2018-02-26 15:10:40 -08:00
Evan Hunt
8c6e4b205c wait for synchronization; re-notify slave if the transfer doesn't happen
(cherry picked from commit 67a8b5ec17)
2018-02-26 15:03:03 -08:00
Evan Hunt
7124e34835 Fix merge error 2018-02-25 23:07:38 -08:00
Mark Andrews
5ef8b93129 remove deadcode
(cherry picked from commit b71a1386ed)
(cherry picked from commit 0beff002bd)
2018-02-26 10:54:19 +11:00
Mark Andrews
9d0effb471 remove unused struct dst_context declaration
(cherry picked from commit f2c22662cc)
(cherry picked from commit 00799ab805)
2018-02-26 10:54:18 +11:00
Evan Hunt
8f4610f773 Merge branch 'tidy-runall.sh-environment-variables-v9_11-v9_10-v9_9' into 'v9_9'
Tidy runall.sh environment variables

See merge request isc-projects/bind9!18
2018-02-25 13:34:35 -08:00
Michał Kępień
1f42e865d2 Preserve values of environment variables which are already set
This enables the environment variables controlling run.sh behavior to be
permanently set in a working environment (e.g. to automatically force
colored output without using "-c" in each runall.sh invocation).

Relevant runall.sh command line arguments still have a higher priority.

(cherry picked from commit d989d20fe5)
(cherry picked from commit 2cd174dda9)
(cherry picked from commit fdcac29f63)
2018-02-25 13:34:35 -08:00
Michał Kępień
a7ae215925 Allow forcing colored system test output
As parallel.mk and runsequential.sh both pipe system test output through
"tee" (for the purpose of creating test.output), run.sh invoked from
these two files detects it is not writing to a terminal, which prevents
colored output from being generated.  Allow forcing colored output using
a new command line argument for runall.sh, "-c", which sets an
environment variable (SYSTEMTEST_FORCE_COLOR) causing conf.sh to
unconditionally enable colored output.

The same environment variable can also be used directly to force colored
output when using "make test" instead of runall.sh.

(cherry picked from commit a324031a82)
(cherry picked from commit cbebf7ef59)
(cherry picked from commit 2f3b3b7aff)
2018-02-25 13:34:35 -08:00
Michał Kępień
fcefc77d35 Allow retaining system test output using an environment variable
Instead of exporting an environment variable containing a command line
argument (NOCLEAN="-n"), extend run.sh to handle a "boolean" environment
variable (SYSTEMTEST_NO_CLEAN) itself.  The former method is buggy
because the value of NOCLEAN is set in parallel.mk when that file is
first created, but it is not subsequently updated upon each test run
(because make considers parallel.mk to be up to date).

To retain backward compatibility, the "-n" command line argument for
run.sh is still supported (and has a higher priority than the relevant
environment variable).

The SYSTEMTEST_NO_CLEAN environment variable can also be used directly
to prevent cleanup when using "make test" instead of runall.sh.

Apart from fixing a bug, this simplifies the way runall.sh controls
run.sh behavior due to the Makefile being bypassed.  Direct processing
of environment variables in run.sh is more scalable in the long run,
given that the previously utilized technique, even with its
implementation fixed, would still require Makefile.in to be modified in
two places each time a new flag needed to be passed from runall.sh to
run.sh.

(cherry picked from commit 3862043879)
(cherry picked from commit e9c4dbe361)
(cherry picked from commit 0e3840e4b4)
2018-02-25 13:34:35 -08:00
Evan Hunt
8315e76561 improve reliability of xfer test
(cherry picked from commit 5d7d6881a1)
(cherry picked from commit 09a1a261dc)
(cherry picked from commit 948bd83ce5)
(cherry picked from commit 4160936c92)
2018-02-25 13:34:23 -08:00
Evan Hunt
99db49b439 Merge branch 'parallel-v9_9' into v9_9
chg: dev: Convert most of the remaining system tests to be able to run in parallel [GL #91]

Closes #91

See merge request isc-projects/bind9!59
2018-02-25 13:29:36 -08:00
Evan Hunt
7677cb277a final cleanup
- add CHANGES note
- update copyrights and license headers
2018-02-25 13:13:26 -08:00