6335b1be387359ac461b0c34087bbba98a925a49 |
|
08-Aug-2016 |
Phil Carmody <phil@dovecot.fi> |
lib: tests - give the tests names, using the new macros
The lists of test function declarations and of test functions to call was
basically the same list. Use the new test macros to squash them into one
list, and then chose to name all the tests, so that you can select which
ones to run. This can simplify the debug cycle when some of the tests are
lengthy.
e.g.:
phil@phil:~/repos/dovecot-core$ src/lib/test-lib --match crc
crc32 ................................................................ : ok
0 / 1 tests failed
src/lib is clearly the most complicated case, conversions of others where
filtering would be useful should be trivial following this example.
Signed-off-by: Phil Carmody <phil@dovecot.fi> |
ed1e909434714837f583c9d180c2a16a1c2675c2 |
|
04-Aug-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
lib: Added log throttling API. |
df74b8f6ff432d9a26727669dfed9a15d77efb55 |
|
27-Apr-2016 |
Aki Tuomi <aki.tuomi@dovecot.fi> |
lib: Add PKCS#5 pbkdf1 and 2 |
2686ef87921233609d1d8ec8dee2883facc2c5eb |
|
24-Feb-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
lib: Added unit test to iostream-temp. |
662bb64be818407c6719a69780411f7ca8d6c96f |
|
10-Feb-2016 |
Aki Tuomi <aki.tuomi@dovecot.fi> |
lib: Add ostream-escaped filter |
3ab672903a7ed98263b89180261079870c964831 |
|
26-Jan-2016 |
Timo Sirainen <timo.sirainen@dovecot.fi> |
lib: When closing istream-chain, make sure parent stream is seeked to correct offset.
We were only seeking it earlier if it ended at EOF. |
273a7cf98c20a3794990e2a6fe09cbb63f4ece26 |
|
15-Sep-2015 |
Timo Sirainen <tss@iki.fi> |
lib: Added a simple timing.h API for tracking min/max/avg for events. |
9b3565b09683b48f66de51aebb52786934d1c324 |
|
27-Aug-2015 |
Timo Sirainen <tss@iki.fi> |
lib: Try fixing ec6e672a6e32 (ioloop timeout fixing)
Previous code was broken at least when moving a timeout between ioloops.
This is now tested and works. |
9c0c600b351ec8043f538026937d4273d11812a8 |
|
27-Aug-2015 |
Timo Sirainen <tss@iki.fi> |
Reverted ec6e672a6e32 for now due to some bugs. |
72a7c4f2ba93a723e23c941369a2985d75f240c9 |
|
27-Aug-2015 |
Stephan Bosch <stephan@rename-it.nl> |
ioloop: Delay actual start of a new normal timeout until the next io_loop_run() cycle.
This makes sure that timeouts will not expire before they get a chance to
run. |
9294b9ad2eb112258c247906b53010664f84e57b |
|
16-Jun-2015 |
Timo Sirainen <tss@iki.fi> |
lib: Added o_stream_create_failure_at() to inject EIO at given offset in ostream |
289bb39856d74484c1622d096922acf126dd90fc |
|
16-Jun-2015 |
Timo Sirainen <tss@iki.fi> |
lib: Added i_stream_create_failure_at() to inject EIO at given offset in istream. |
8549b59aa3499ddf0b7b59bc2e083933ebbb4f1f |
|
15-Jun-2015 |
Phil Carmody <phil@dovecot.fi> |
lib: test-failures - tests get/set handlers and the various log levels
Also indirectoy tests the new lib-test test_expect* family.
Signed-off-by: Phil Carmody <phil@dovecot.fi> |
68ae5d6615e80f46d5565735a700ea69869d46a4 |
|
29-Apr-2015 |
Timo Sirainen <tss@iki.fi> |
lib: Renamed test-network to test-net
Since network.c had been renamed to net.c some time ago. |
bf132be3fe1c9e8de84f10d0b05c0b46ca542ac4 |
|
25-Apr-2015 |
Timo Sirainen <tss@iki.fi> |
lib: Added istream-unix for reading fd sockets via istream. |
31e6dbee5fc7d6c33b44c75c7e18ea576f44184b |
|
08-Apr-2015 |
Timo Sirainen <tss@iki.fi> |
lib: Added json-tree API for parsing JSON input into a tree structure.
This makes it easier to access complicated JSON structs that can fit into
memory. |
824809e6423ce89495335aed6748c88d8764eb2a |
|
25-Nov-2014 |
Phil Carmody <phil@dovecot.fi> |
lib: test-array - fatal tests
Tests both of the i_asserts which aren't already protected by TYPEOF compile-time
checks.
Signed-off-by: Phil Carmody <phil@dovecot.fi> |
75f7e423ea22446ed529d33cb660dadf680e13e0 |
|
15-Nov-2014 |
Stephan Bosch <stephan@rename-it.nl> |
Added support for base32 encode/decode. |
639587335dfe5d66dc7034817b3e685458ecbee1 |
|
13-Nov-2014 |
Timo Sirainen <tss@iki.fi> |
lib: Added str-table API for keeping reference counted strings in a hash table. |
3bb59b47d47cba85a92df67823b0e49d2c383307 |
|
22-Oct-2014 |
Timo Sirainen <tss@iki.fi> |
lib: Added unit tests for guid_128_*() |
5a9c7366ed354a7ad309cc17c7cf9951facfedf5 |
|
19-Aug-2014 |
Timo Sirainen <tss@iki.fi> |
lib: Added unit tests for wildcard_match() |
ee2298ffa2c91fa156ba5ba05d45576a99d3f9ad |
|
30-Jul-2014 |
Phil Carmody <phil@dovecot.fi> |
lib: test-data-stack - add some fatal tests.
Extra caution is necessary as data-stack is such a fundamental component.
All of the brokenness that we add must be undone as soon as possible, or
there will be an endless loop of catastrophic errors. In order to avoid
that, at least try to detect some issues, and abort as quickly as possible.
Alas, due to the reliance of these tests on DEBUG code, if that's not set,
this test is a no-op.
Signed-off-by: Phil Carmody <phil@dovecot.fi> |
8bec19723b39071a1794e76dec35d151473cae5f |
|
30-Jul-2014 |
Phil Carmody <phil@dovecot.fi> |
lib: test fatal cases for printf_format_fix
Signed-off-by: Phil Carmody <phil@dovecot.fi> |
8b2839664b4b1730d7d5fd5c1856e97e34934a3d |
|
30-Jul-2014 |
Phil Carmody <phil@dovecot.fi> |
lib: test-lib - add a real fatal test for mempool-alloconly
Crazily huge memory allocation must fail.
Signed-off-by: Phil Carmody <phil@dovecot.fi> |
992a1726a41b42fa47204565ff17f7c635fcb421 |
|
28-Jul-2014 |
Phil Carmody <phil@dovecot.fi> |
lib: test-data-stack - too important a library not to be thrashed hard
OK, it's thrashed a bit by other tests such as aqueue, str, etc., but these
tests attempt to probe all corner cases given detailed knowledge of the
limits of the block/frame implementation.
At the moment, no realloc functionality is tested, as with DEBUG builds
they would fail very noisily.
Signed-off-by: Phil Carmody <phil@dovecot.fi> |
42826d96c8d0bba9eddc85b01bf70d7db571ae7f |
|
02-Jul-2014 |
Phil Carmody <phil@dovecot.fi> |
lib: test-lib - add unit tests for str_to_*() helpers
This doesn't test all the helpers, but ensures both signed and unsigned
are tested, as are 32-bit and 64-bit cases. All the other helpers fall
back onto using one of those cases. Unless uintmax_t is larger than 64
bits, in which case this needs a revisit.
NOTE: This causes the following make check errors:
test-strnum.c:35: Assert(#7) failed: ret == u64tests[i].ret
test-strnum.c:35: Assert(#10) failed: ret == u64tests[i].ret
test-strnum.c:37: Assert(#10) failed: val == u64tests[i].val
str_to_uint64 ........................................................ : FAILED
Corresponding to test cases:
[7] = INVALID(18446744073709551616),
This does not wrap-past-0 (become smaller) on multiply, but wraps-past-0 on addition.
[10]= INVALID(20496382304121724020),
This wraps-past-n (becomes larger) on multiply.
Signed-off-by: Phil Carmody <phil@dovecot.fi> |
1d940afbc02516d8c3d016780e1223a779844a1e |
|
27-Jun-2014 |
Phil Carmody <phil@dovecot.fi> |
lib: test printf_format_fix()
Signed-off-by: Phil Carmody <phil@dovecot.fi> |
f5982bb5b0a704e88fa2b44b0b74e365d13103b9 |
|
19-Jun-2014 |
Timo Sirainen <tss@iki.fi> |
lib: If two istreams share one parent, i_stream_get_data() may have returned corrupted data to another.
This happened only for istreams that used parent's buffer directly instead
of having their own buffer. For now at least we've solved this by truncating
the other stream's buffer so it needs to be read again. Hopefully this is
good enough.
Added also unit test to check this functionality. |
9fe07780492524a34423686794bc1b4061206246 |
|
09-Jun-2014 |
Phil Carmody <phil@dovecot.fi> |
lib: unit tests for lib/bits
Signed-off-by: Phil Carmody <phil@dovecot.fi> |
44af44edbffb19d33e109b4eb74d41f4fbb2e04a |
|
09-Jun-2014 |
Timo Sirainen <tss@iki.fi> |
lib: Added some kind of a unit test for hash table.
Just try out some insert+deletes randomly. Mainly I wrote this to check if
there is some obvious problem, but looks like not. |
b0114f9348060796a29a9042af757e8f99cdd422 |
|
07-May-2014 |
Timo Sirainen <tss@iki.fi> |
liblib: Added unit test for hash methods to make sure they don't do read access beyond buffer.
This currently fails for MD4 and MD5, so they need to be fixed/replaced.. |
8e4a702a1f96f118976da6eb9ece344df625eabb |
|
15-Jan-2013 |
Timo Sirainen <tss@iki.fi> |
buffer: Always keep +1 byte available for str_c()'s NUL. |
86763e4c68313df83606e1060fc1795280590677 |
|
04-Jan-2013 |
Timo Sirainen <tss@iki.fi> |
uni_utf8_*(): Treat overlong UTF8 sequences as invalid. |
ae9691f7ef36d5272d72c90fa51393dfea5dd126 |
|
29-Nov-2012 |
Timo Sirainen <tss@iki.fi> |
JSON parser supports now nested objects and parsing from non-blocking input stream. |
3f73764415873c1d7c9a284f19bbc124c4c9ac7b |
|
11-Aug-2012 |
Timo Sirainen <tss@iki.fi> |
liblib: Added "number packing" API. |
3700eab7818bcf8a68424c418485ae4e8770865d |
|
10-Aug-2012 |
Timo Sirainen <tss@iki.fi> |
Added istream-base64-decoder. |
5fb662c8dff409ed8c8385cde59325b944af66b4 |
|
02-Jun-2012 |
Stephan Bosch <stephan@rename-it.nl> |
Adds ISO8601/RFC3339 date format parsing and construction support.
Interface is somewhat based on message date parser in src/lib-mail, but it
also provides access to struct tm. |
6a3a0723319ea31343ea6f03f40672c4b533b21d |
|
15-Nov-2010 |
Timo Sirainen <tss@iki.fi> |
Added unit test for istream-base64-encoder. |
37bd98570b30513255a19cc52de16594bc4256e0 |
|
19-Oct-2010 |
Timo Sirainen <tss@iki.fi> |
liblib: Added API for easily building hash strings based on given format string and input. |
08baf8e4f38f6e5858b16e954e1841675cecae0c |
|
18-Oct-2010 |
Timo Sirainen <tss@iki.fi> |
ostream-file: Fixed potential crash in write_at() and also fixed attempted optimization. |
3efdcb59492bd1e0602340a4204003a32b34654a |
|
05-Feb-2010 |
Timo Sirainen <tss@iki.fi> |
crc32*() didn't return a standard CRC32 value.
--HG--
branch : HEAD |
927d3977d5598f12ae18d4fa3f22b9e913f7dd46 |
|
23-Dec-2009 |
Timo Sirainen <tss@iki.fi> |
var_expand(): Added support for built-in host, pid and env:* variables.
--HG--
branch : HEAD |
12ff27eadb44c6877298d3e214c7039342669669 |
|
12-Dec-2009 |
Timo Sirainen <tss@iki.fi> |
Added p_strarray_dup().
--HG--
branch : HEAD |
9761e0036c87f459abe040632e1252f794ffe5f7 |
|
06-Nov-2009 |
Timo Sirainen <tss@iki.fi> |
Added DLLIST2_*() functions for doubly linked list with head and tail.
--HG--
branch : HEAD |
7d548d4984752d74bfea8dc4bf1781a8996f43e7 |
|
26-Oct-2009 |
Timo Sirainen <tss@iki.fi> |
Added unit tests for istream-seekable istream-concat.
--HG--
branch : HEAD |
03888f9891b45c024f2bdc8e55438528b78bd96e |
|
14-Aug-2009 |
Timo Sirainen <tss@iki.fi> |
Added unit test for istream-tee.
--HG--
branch : HEAD |
4332108b1bff778b866f6421771578e7c6633098 |
|
14-Aug-2009 |
Timo Sirainen <tss@iki.fi> |
Renamed test-istream.c to test-istream-crlf.c
--HG--
branch : HEAD |
bc6a872cc6cecb4e3f8d0a99236c4ab484f2f754 |
|
12-Aug-2009 |
Timo Sirainen <tss@iki.fi> |
Added unit tests for timeval_*().
--HG--
branch : HEAD |
002db944c36f6d6021aa2c0518e2f117bff4bf3a |
|
16-Jul-2009 |
Timo Sirainen <tss@iki.fi> |
Added binary_to_hex_append().
--HG--
branch : HEAD |
047ebb958b682bc058097eddc34df574c3f3d6d4 |
|
16-Jun-2009 |
Timo Sirainen <tss@iki.fi> |
Added str_append_tabunescaped(). str_tabescape*() now escapes also CR. Added unit tests.
--HG--
branch : HEAD |
48acc31adebfdd4e4945ee76e1f5259e4b1b6fff |
|
01-Jun-2009 |
Timo Sirainen <tss@iki.fi> |
liblib unit tests are now split to separate files.
--HG--
branch : HEAD |
40a5aeebf6b4858b93f0ddff0bf12fba769cf903 |
|
09-May-2009 |
Timo Sirainen <tss@iki.fi> |
Tests are now run on "make check". Added initial tests for lib-index.
Moved old tests away from tests/ to libraries' individual directories.
--HG--
branch : HEAD |