ddnet/src/test
def d9804f5142 str_format: always return length of written string
Quoting the man page of vsnprintf:

RETURN VALUE
  Upon successful return, these functions  return  the  number  of  characters  printed
  (excluding the null byte used to end output to strings).

  The functions snprintf() and vsnprintf() do not write more than size bytes (including
  the terminating null byte ('\0')).  If the output was truncated due  to  this  limit,
  then  the  return  value  is the number of characters (excluding the terminating null
  byte) which would have been written to the final string  if  enough  space  had  been
  available.  Thus, a return value of size or more means that the output was truncated.
  (See also below under NOTES.)

  If an output error is encountered, a negative value is returned.

[...]

  The glibc implementation of the functions snprintf() and vsnprintf() conforms to  the
  C99  standard,  that  is, behaves as described above, since glibc version 2.1.  Until
  glibc 2.0.6, they would return -1 when the output was truncated.
2019-03-21 13:39:25 +01:00
..
aio.cpp Add manual locking to ASYNCIO for transacted writes 2017-11-27 01:04:55 +01:00
datafile.cpp Add support for extra map items in datafiles 2018-10-08 23:05:56 +02:00
fs.cpp Add CTestInfo class, add test for create-close-remove process 2017-10-23 00:13:53 +02:00
git_revision.cpp Use EXPECT_* rather than ASSERT_* in tests 2019-03-12 02:06:54 +01:00
hash.cpp Also use sha256 for the mapbugs stuff 2018-08-19 12:12:11 +02:00
jobs.cpp Add a couple of tests for CJobPool 2017-11-24 10:33:42 +01:00
json.cpp Remove /modhelp (fixes #1401) 2018-12-12 10:05:44 +01:00
mapbugs.cpp Also use sha256 for the mapbugs stuff 2018-08-19 12:12:11 +02:00
name_ban.cpp Use EXPECT_* rather than ASSERT_* in tests 2019-03-12 02:06:54 +01:00
str.cpp str_format: always return length of written string 2019-03-21 13:39:25 +01:00
strip_path_and_extension.cpp Add testing infrastructure for teehistorian 2017-09-28 02:03:30 +02:00
teehistorian.cpp Add colors for authed players. Deprecates #1299 2019-03-02 13:50:33 +03:00
test.cpp Call net_init in tests 2017-11-24 10:51:46 +01:00
test.h Add CTestInfo class, add test for create-close-remove process 2017-10-23 00:13:53 +02:00
thread.cpp More error checking in system.c (fixes #1317) 2019-03-19 23:16:29 +01:00
unix.cpp Add very basic test for Unix sockets 2017-12-20 16:56:44 +01:00