mirror of
https://github.com/zeek/zeek.git
synced 2025-10-17 14:08:20 +00:00
Added Jon's test cases as unit tests
This commit is contained in:
parent
3efbea0b84
commit
6fcb23066d
4 changed files with 64 additions and 0 deletions
|
@ -0,0 +1,21 @@
|
|||
#
|
||||
# @TEST-EXEC: zeek -b %INPUT
|
||||
# @TEST-EXEC: btest-diff test.log
|
||||
|
||||
@load tuning/enable-utf-8-logs
|
||||
|
||||
module Test;
|
||||
export {
|
||||
redef enum Log::ID += { LOG };
|
||||
|
||||
type Log: record {
|
||||
s: string;
|
||||
} &log;
|
||||
}
|
||||
|
||||
event zeek_init()
|
||||
{
|
||||
local a = "foo \n\t\0 bar";
|
||||
Log::create_stream(Test::LOG, [$columns=Log]);
|
||||
Log::write(Test::LOG, [$s=a]);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue