Pavel Tvrdík
3352922b77
Birdtest: fix usage of variable argument lists
2016-03-30 17:05:16 +02:00
Pavel Tvrdík
decab56092
Birdtest: remove bad buffer initialization
2016-03-30 17:03:35 +02:00
Pavel Tvrdík
3b59d07582
Small change in birdtest.h
...
Thanks to Martin Mares.
2015-11-03 09:26:38 +01:00
Pavel Tvrdík
2fcae1f9fc
Birdtest: do not use strcpy()
2015-11-02 13:28:15 +01:00
Pavel Tvrdík
c8f081e5e8
Birdtest: Fixing macro ARGip4(x) for non-debugging environment
2015-09-01 08:54:59 +02:00
Pavel Tvrdík
4fb506466c
Birdtest: filter/trie
...
Thanks to Santiago for reuse here his code.
bt_rand_num() -> bt_random()
2015-08-28 15:56:35 +02:00
Pavel Tvrdík
45e65e8232
Birdtest: fixing test framework build
2015-08-19 15:11:10 +02:00
Pavel Tvrdík
daaa115943
Birdtest: add some utils to framework
...
and updates old tests
2015-08-19 14:57:34 +02:00
Pavel Tvrdík
39059e21b7
Birdtest: Add unfinished filter test
...
Add birdtest utils for testing parsing configurations files
Add tests with parsing filter examples
2015-08-14 16:14:32 +02:00
Pavel Tvrdík
aa96f486e0
Birdtest: Improve reliable
...
Fixing some bugs
Add option to call birdtest with an argument (void *)
2015-08-14 16:08:04 +02:00
Pavel Tvrdík
e0176f2639
Birdtest: Clean up unit tests from mock-ups
2015-08-05 12:36:40 +02:00
Pavel Tvrdík
aad0af2fd7
Birdtest: Add an another verbose level for tests
2015-08-04 14:40:40 +02:00
Pavel Tvrdík
ddb80bd8c5
unsigned [int] -> uint
2015-05-19 08:53:34 +02:00
Pavel Tvrdík
c23cd84ed5
Add HMAC-SHA256 hash library and unit tests
2015-04-25 13:43:49 +02:00
Pavel Tvrdík
26b1fd1dc4
Add SHA256, SHA224 hash libraries and unit tests
2015-04-23 15:19:36 +02:00
Pavel Tvrdík
5245c4dd6d
Birdtest: add io_log_event() mockup
2015-04-20 16:50:51 +02:00
Pavel Tvrdík
5419d2a3c5
Birdtest: Compability bug fixes
...
Tested on Ubuntu & FreeBSD & NetBSD & OpenBSD
2015-04-15 15:42:43 +02:00
Pavel Tvrdík
1ce8d33b80
Birdtest: Improve the testing framework
...
- non-blocking asserts, only set bt_test_suite_success
- unification of testing output from bt_assert_fn_in_out and bt_assert_out_fn_in
2015-04-15 11:51:24 +02:00
Pavel Tvrdík
a84b9c62d1
Birdtest: Add bt_assert_fn_in_*
...
- Improved test output formating: aligned, colored [ OK ] / [FAIL]
- A failed assert will not interupt the whole test suite
- bt_assert_fn_in_* are macros for testing input and output from the some
function
2015-04-13 10:52:21 +02:00
Pavel Tvrdík
947018a7ef
Birdtest: bt_test_case() -> bt_test_suite()
2015-04-13 10:42:10 +02:00
Pavel Tvrdík
83131f3fa5
Birdtest: Add Event Processing Tests
...
Add test/birdtest_support.h for provisional hack a build system
2015-04-03 12:52:44 +02:00
Pavel Tvrdík
e7bb2daf1f
Birdtest: improve bt_check macro
...
Now dat for testing can be defined somelike this:
struct in_out_data_ {
char *in;
u32 out;
} in_out_data[] = {
{
.in = "192.168.1.128",
.out = build_ip4(192, 168, 1, 128),
},
{
.in = "255.255.255.255",
.out = build_ip4(255, 255, 255, 255),
},
...
};
bt_check(ip4_pton_, in_out_data, "%s", "0x%08X");
2015-04-03 12:46:04 +02:00
Pavel Tvrdík
1bdf2a54ed
Birdtest: move def bt_rand_num() at a better place
2015-04-03 12:44:47 +02:00
Pavel Tvrdík
4b5e005d57
Birdtest: Add printing backtrace while segfault
2015-04-03 12:42:49 +02:00
Pavel Tvrdík
8edf5b99e8
Birdtest: Add bt_check()
...
- A function for check test some other function for
in and out/expected data in array.
2015-03-27 14:04:37 +01:00
Pavel Tvrdík
cf545a3ceb
Birdtest: Add bt_rand_num()
2015-03-27 14:03:47 +01:00
Pavel Tvrdík
f26cf70152
Birdtest: Refactore tests and build system
...
Rename directory:
birdtest/* -> test/*
Rename Makefile rule:
build-tests -> tests
Move run-all-test shell script from Makefile to stand-alone shell script
Simplify Makefile test build system
2015-03-23 17:40:13 +01:00