mirror of
https://github.com/zeek/zeek.git
synced 2025-10-10 10:38:20 +00:00
Merge remote-tracking branch 'origin/topic/dnthayer/ticket1821'
* origin/topic/dnthayer/ticket1821: Remove loading of listen.bro in tests that do not need it Serialize tests that load listen.bro Fix race condition causing some tests to fail Fix a race condition in some failing tests The broccoli-v6addrs "-r" option was renamed to "-R" Fix a race condition in some failing tests
This commit is contained in:
commit
7ff5ca1df9
16 changed files with 23 additions and 24 deletions
|
@ -1,2 +1,2 @@
|
|||
error in /home/robin/bro/master/testing/btest/.tmp/language.expire-expr-error/expire-expr-error.bro, line 7: no such index (x[kaputt])
|
||||
error in /home/robin/bro/master/testing/btest/.tmp/language.expire-expr-error/expire-expr-error.bro, line 8: no such index (x[kaputt])
|
||||
received termination signal
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
# @TEST-SERIALIZE: comm
|
||||
# @TEST-EXEC: bro -b -X broxygen.config %INPUT
|
||||
# @TEST-EXEC: btest-diff test.rst
|
||||
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
# @TEST-SERIALIZE: comm
|
||||
# @TEST-EXEC: bro -b -X broxygen.config %INPUT
|
||||
# @TEST-EXEC: btest-diff test.rst
|
||||
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
# @TEST-SERIALIZE: comm
|
||||
# @TEST-EXEC: bro -b -X broxygen.config %INPUT
|
||||
# @TEST-EXEC: btest-diff test.rst
|
||||
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
# @TEST-SERIALIZE: comm
|
||||
# @TEST-EXEC: bro -b -X broxygen.config %INPUT
|
||||
# @TEST-EXEC: btest-diff test.rst
|
||||
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
# @TEST-SERIALIZE: comm
|
||||
# @TEST-EXEC: bro -b -X broxygen.config %INPUT
|
||||
# @TEST-EXEC: btest-diff test.rst
|
||||
|
||||
|
|
|
@ -4,8 +4,7 @@
|
|||
# @TEST-REQUIRES: ifconfig | grep -q -E "inet6 ::1|inet6 addr: ::1"
|
||||
#
|
||||
# @TEST-EXEC: btest-bg-run bro bro $DIST/aux/broccoli/test/broccoli-v6addrs.bro "Communication::listen_ipv6=T"
|
||||
# @TEST-EXEC: sleep 3
|
||||
# @TEST-EXEC: btest-bg-run broccoli $BUILD/aux/broccoli/test/broccoli-v6addrs -6 ::1
|
||||
# @TEST-EXEC: btest-bg-run broccoli $BUILD/aux/broccoli/test/broccoli-v6addrs -R -6 ::1
|
||||
# @TEST-EXEC: btest-bg-wait 20
|
||||
# @TEST-EXEC: btest-diff bro/.stdout
|
||||
# @TEST-EXEC: btest-diff broccoli/.stdout
|
||||
|
|
|
@ -3,8 +3,7 @@
|
|||
# @TEST-REQUIRES: test -e $BUILD/aux/broccoli/src/libbroccoli.so || test -e $BUILD/aux/broccoli/src/libbroccoli.dylib
|
||||
#
|
||||
# @TEST-EXEC: btest-bg-run bro bro $DIST/aux/broccoli/test/broccoli-v6addrs.bro
|
||||
# @TEST-EXEC: sleep 1
|
||||
# @TEST-EXEC: btest-bg-run broccoli $BUILD/aux/broccoli/test/broccoli-v6addrs
|
||||
# @TEST-EXEC: btest-bg-run broccoli $BUILD/aux/broccoli/test/broccoli-v6addrs -R
|
||||
# @TEST-EXEC: btest-bg-wait 20
|
||||
# @TEST-EXEC: btest-diff bro/.stdout
|
||||
# @TEST-EXEC: btest-diff broccoli/.stdout
|
||||
|
|
|
@ -4,8 +4,7 @@
|
|||
#
|
||||
# @TEST-EXEC: chmod 600 broccoli.conf
|
||||
# @TEST-EXEC: btest-bg-run bro bro $DIST/aux/broccoli/test/broccoli-v6addrs.bro "Communication::listen_ssl=T" "ssl_ca_certificate=../ca_cert.pem" "ssl_private_key=../bro.pem"
|
||||
# @TEST-EXEC: sleep 5
|
||||
# @TEST-EXEC: btest-bg-run broccoli BROCCOLI_CONFIG_FILE=../broccoli.conf $BUILD/aux/broccoli/test/broccoli-v6addrs
|
||||
# @TEST-EXEC: btest-bg-run broccoli BROCCOLI_CONFIG_FILE=../broccoli.conf $BUILD/aux/broccoli/test/broccoli-v6addrs -R
|
||||
# @TEST-EXEC: btest-bg-wait 20
|
||||
# @TEST-EXEC: btest-diff bro/.stdout
|
||||
# @TEST-EXEC: btest-diff broccoli/.stdout
|
||||
|
|
|
@ -3,8 +3,7 @@
|
|||
# @TEST-REQUIRES: test -e $BUILD/aux/broccoli/src/libbroccoli.so || test -e $BUILD/aux/broccoli/src/libbroccoli.dylib
|
||||
#
|
||||
# @TEST-EXEC: btest-bg-run bro bro $DIST/aux/broccoli/test/broccoli-vectors.bro
|
||||
# @TEST-EXEC: sleep 1
|
||||
# @TEST-EXEC: btest-bg-run broccoli $BUILD/aux/broccoli/test/broccoli-vectors
|
||||
# @TEST-EXEC: btest-bg-run broccoli $BUILD/aux/broccoli/test/broccoli-vectors -R
|
||||
# @TEST-EXEC: btest-bg-wait 20
|
||||
# @TEST-EXEC: btest-diff bro/.stdout
|
||||
# @TEST-EXEC: btest-diff broccoli/.stdout
|
||||
|
|
|
@ -3,8 +3,7 @@
|
|||
# @TEST-REQUIRES: test -e $BUILD/aux/broccoli/src/libbroccoli.so || test -e $BUILD/aux/broccoli/src/libbroccoli.dylib
|
||||
#
|
||||
# @TEST-EXEC: btest-bg-run bro bro %INPUT $DIST/aux/broccoli/test/broping-record.bro
|
||||
# @TEST-EXEC: sleep 1
|
||||
# @TEST-EXEC: btest-bg-run broccoli $BUILD/aux/broccoli/test/broping -r -c 3 127.0.0.1
|
||||
# @TEST-EXEC: btest-bg-run broccoli $BUILD/aux/broccoli/test/broping -R -r -c 3 127.0.0.1
|
||||
# @TEST-EXEC: btest-bg-wait 20
|
||||
# @TEST-EXEC: cat bro/ping.log | sed 's/one-way.*//g' >bro.log
|
||||
# @TEST-EXEC: cat broccoli/.stdout | sed 's/time=.*//g' >broccoli.log
|
||||
|
|
|
@ -1,13 +1,12 @@
|
|||
# @TEST-EXEC: btest-bg-run broproc bro %INPUT
|
||||
# @TEST-EXEC: btest-bg-wait -k 5
|
||||
# @TEST-EXEC: cat broproc/.stderr > output
|
||||
# @TEST-EXEC: bro -b %INPUT
|
||||
# @TEST-EXEC: cp .stderr output
|
||||
# @TEST-EXEC: TEST_DIFF_CANONIFIER=$SCRIPTS/diff-remove-abspath btest-diff output
|
||||
|
||||
redef exit_only_after_terminate = T;
|
||||
|
||||
global x: table[string] of interval;
|
||||
global data: table[int] of string &create_expire=x["kaputt"];
|
||||
|
||||
@load frameworks/communication/listen
|
||||
|
||||
global runs = 0;
|
||||
event do_it()
|
||||
{
|
||||
|
@ -16,6 +15,8 @@ event do_it()
|
|||
++runs;
|
||||
if ( runs < 4 )
|
||||
schedule 1sec { do_it() };
|
||||
else
|
||||
terminate();
|
||||
}
|
||||
|
||||
|
||||
|
@ -24,6 +25,3 @@ event bro_init() &priority=-10
|
|||
data[0] = "some data";
|
||||
schedule 1sec { do_it() };
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -3,8 +3,6 @@
|
|||
|
||||
redef exit_only_after_terminate = T;
|
||||
|
||||
@load frameworks/communication/listen
|
||||
|
||||
const exp_val = -1sec &redef;
|
||||
|
||||
global expired: function(tbl: table[int] of string, idx: int): interval;
|
||||
|
|
|
@ -9,9 +9,10 @@
|
|||
1.2.3.4 Intel::ADDR source1 this host is bad http://some-data-distributor.com/1
|
||||
# @TEST-END-FILE
|
||||
|
||||
@load frameworks/communication/listen
|
||||
@load frameworks/intel/do_expire
|
||||
|
||||
redef exit_only_after_terminate = T;
|
||||
|
||||
redef Intel::read_files += { "../intel.dat" };
|
||||
redef enum Intel::Where += { SOMEWHERE };
|
||||
redef Intel::item_expiration = 9sec;
|
||||
|
@ -44,6 +45,8 @@ event do_it()
|
|||
|
||||
if ( runs < 6 )
|
||||
schedule 3sec { do_it() };
|
||||
else
|
||||
terminate();
|
||||
}
|
||||
|
||||
event Intel::match(s: Intel::Seen, items: set[Intel::Item])
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
192.168.128.0/18 Intel::SUBNET source1 this subnetwork might be baaad http://some-data-distributor.com/5
|
||||
# @TEST-END-FILE
|
||||
|
||||
@load frameworks/communication/listen
|
||||
redef exit_only_after_terminate = T;
|
||||
|
||||
redef Intel::read_files += { "../intel.dat" };
|
||||
redef enum Intel::Where += { SOMEWHERE };
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
192.168.1.1 Intel::ADDR source1 this host is just plain baaad http://some-data-distributor.com/1
|
||||
# @TEST-END-FILE
|
||||
|
||||
@load frameworks/communication/listen
|
||||
redef exit_only_after_terminate = T;
|
||||
|
||||
redef Intel::read_files += { "../intel.dat" };
|
||||
redef enum Intel::Where += { SOMEWHERE };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue