Commit Graph

704 Commits

Author SHA1 Message Date
Will Thompson
5e2a2ef288 g_parse_debug_string: invert flags given besides "all"
Any flags specified as well as "all" are subtracted from the result,
allowing the user to specify FOO_DEBUG="all,bar,baz" to mean "give me
debugging information for everything except bar and baz".

https://bugzilla.gnome.org/show_bug.cgi?id=642452
2011-10-24 20:35:30 -04:00
Will Thompson
73ffa9034f Test g_parse_debug_string ("all")
https://bugzilla.gnome.org/show_bug.cgi?id=642452
2011-10-24 20:26:22 -04:00
Matthias Clasen
94a46ea410 Fix 'make check' with clang
Patch by Elias Pipping

https://bugzilla.gnome.org/show_bug.cgi?id=662491
2011-10-24 13:43:11 -04:00
Javier Jardón
4a25d21bd0 tests/gobject: Use G_VALUE_INIT 2011-10-18 17:12:33 +01:00
Ryan Lortie
ef6371ff74 tests/Makefile.am: remove unused LDFLAGS variable 2011-10-15 13:13:13 -04:00
Ryan Lortie
fd382156b8 tests: disable deprecation warnings for tests
We need to test deprecated functions, so don't warn us for doing so.
2011-10-13 10:51:35 -04:00
Ryan Lortie
6f343ca548 Remove g_mutex_new()/g_cond_new() in testcases
These were the last users of the dynamic allocation API.

Keep the uses in glib/tests/mutex.c since this is actually meant to test
the API (which has to continue working, even if it is deprecated).

https://bugzilla.gnome.org/show_bug.cgi?id=660739
2011-10-04 19:35:27 -04:00
Ryan Lortie
9793708931 drop errorcheck mutex test
We don't support errorchecking mutexes in GLib anymore.
2011-10-04 18:52:55 -04:00
Ryan Lortie
2a677d1370 locks: drop _INIT macros
All locks are now zero-initialised, so we can drop the G_*_INIT macros
for them.

Adjust various users around GLib accordingly and change the docs.

https://bugzilla.gnome.org/show_bug.cgi?id=659866
2011-10-02 22:33:10 -04:00
Matthias Clasen
151756631d Don't use g_thread_foreach in tests 2011-10-02 22:31:45 -04:00
Javier Jardón
3659ca99f5 tests: Use G_VALUE_INIT 2011-10-02 17:22:57 +01:00
Colin Walters
f42fe6cdc0 gvalue: Add explicitly signed g_value_get_schar() and g_value_set_schar()
The documentation for G_TYPE_CHAR says:

"The type designated by G_TYPE_CHAR is unconditionally an 8-bit signed
 integer."

However the return value for g_value_get_char() was just "char" which
in C has an unspecified signedness; on e.g. x86 it's signed (which
matches the GType), but on e.g. PowerPC or ARM, it's not.

We can't break the old API, so we need to suck it up and add new API.
Port most internal users, but keep some tests of the old API too.

https://bugzilla.gnome.org/show_bug.cgi?id=659870
2011-09-22 20:05:38 -04:00
Ryan Lortie
14e6377a60 Deprecate g_thread_create_full()
Replace it with g_thread_create_with_stack_size() and a real function
implementation of g_thread_create().

Modify a testcase that was calling g_thread_create_full()
inappropriately (it was using the default values anyway).
2011-09-21 16:06:55 -04:00
Ryan Lortie
c33cd00739 Stop using GStaticMutex in two testcases 2011-09-21 16:06:53 -04:00
Dan Winship
5bc7729d16 Make threads mandatory
G_THREADS_ENABLED still exists, but is always defined. It is still
possible to use libglib without threads, but gobject (and everything
above it) is now guaranteed to be using threads (as, in fact, it was
before, since it was accidentally impossible to compile with
--disable-threads).

https://bugzilla.gnome.org/show_bug.cgi?id=616754
2011-09-09 12:41:55 -04:00
Dan Winship
350a1cda0a update .gitignore 2011-09-04 17:50:41 -04:00
Matthias Clasen
1b28408b8b Spelling fixes
Spelling fixes in comments and docs, provided by
Kjartan Maraas in bug 657336.
2011-08-29 14:49:32 -04:00
Matthias Clasen
76856241d0 Add a quick utility to test datetime formatting 2011-08-21 21:33:30 -04:00
Matthias Clasen
b76bb6713b Add g_mkdtemp in the spirit of g_mkstemp
At the same time, also add g_mkdtemp_full and g_dir_make_tmp
variants. The patch also unifies the unique-name-generating
code for all variants of mkstemp and mkdtemp and adds tests
for the new functions.

Based on patches by Paolo Bonzini,
http://bugzilla.gnome.org/show_bug.cgi?id=118563
2011-08-14 14:09:58 -04:00
Ryan Lortie
dbd0d63b6b wait longer in threadpool test case
If we are going to fail an assert, wait for a bit longer before doing so
(up to 5 seconds, if needed).

This is a long-standing Debian patch to fix build failures on really
slow machines.
2011-07-20 10:51:16 +02:00
Matthias Clasen
9fa5b8e5c7 asyncqueue: improve test coverage 2011-06-19 01:05:26 -04:00
Ryan Lortie
ce9681b87e Drop a few more G_CONST_RETURN 2011-06-13 09:27:28 -04:00
Matthias Clasen
abf4a0200f Test runtime dir getter 2011-06-06 00:30:30 -04:00
Matthias Clasen
1f022a88d4 Remove deprecated atomic functions from tests 2011-06-06 00:30:02 -04:00
Antoine Jacoutot
2ee470a71f Don't hardcode path to true(1).
true(1) is not always installed under /bin so leave system() find
it in the PATH.

https://bugzilla.gnome.org/show_bug.cgi?id=651219
2011-05-27 12:00:41 -04:00
Matthias Clasen
e5c986cbcf Only remove the lines that are no longer needed 2011-05-03 12:41:11 -04:00
Matthias Clasen
5d1aba2464 Revert "[build] Remove stale LDADD lines from tests/Makefile.am to allow build"
This reverts commit b0874ce28e.
2011-05-03 12:37:45 -04:00
Dan Winship
33c0877adc Add back an erroneously-removed line to tests/Makefile.am 2011-05-02 17:06:37 -04:00
Dan Winship
bdc23c44e8 Fix compiler warnings 2011-05-02 11:50:23 -04:00
Behdad Esfahbod
b0874ce28e [build] Remove stale LDADD lines from tests/Makefile.am to allow build
Automake 1.11 wasn't happy.
2011-05-02 11:43:18 -04:00
Matthias Clasen
ef5d4d55fe Fix make check
g_thread_init() causes a hash table to be allocated (in read_aliases).
Since hash tables are now a bit larger, we need to bump one of the
probe sizes to avoid our probe slice being used for the aliases
hash table.
2011-05-01 17:10:04 -04:00
Matthias Clasen
bd8b245f57 Update Unicode tests to 6.0 2011-01-22 00:02:08 -05:00
Matthias Clasen
316be2748f Adapt testglib.c to GRelation deprecation
Patch by Chun-wei Fan, bug https://bugzilla.gnome.org/show_bug.cgi?id=637858
2010-12-28 00:12:19 -05:00
Matthias Clasen
bf1027f826 Move ifaceproperties test to gobject/tests/ 2010-12-27 23:49:12 -05:00
Matthias Clasen
2a5e0cf9e0 Convert ifaceproperties.c to test framework
Also add a test that checks warnings for failure to implement
interface properties.

See https://bugzilla.gnome.org/show_bug.cgi?id=637738
2010-12-27 23:40:28 -05:00
Tor Lillqvist
46390c9d10 Don't call close() on -1
Of course, a proper implementation of close() will just ignore an
invalid parameter silently, and set errno. But apparently the "debug"
version of the Microsoft C library generates some noise in this
case. So avoid that. Thanks to John Emmas for reporting.
2010-10-07 12:06:48 +03:00
Jens Georg
db7ddcc195 Improve parsing of date-only iso8601 strings 2010-08-26 18:18:52 +03:00
Dan Winship
8f5ec0dad3 Fix misc compiler warnings in (mostly) test programs 2010-08-19 18:24:53 -04:00
Ryan Lortie
b3b7ea8e22 Replace -I with $(glib_INCLUDES) and friends
Stop using ad hoc -I in all of our Makefile.am.  Use the new variables
instead.
2010-08-06 13:10:34 -04:00
paul
9f6faaffb6 Add $(top_builddir)/glib to includes
This is required to find glibconfig.h during srcdir != builddir builds
2010-08-05 09:08:34 -04:00
Matthias Clasen
5179d92e9c fix the completion test 2010-08-03 10:25:54 -04:00
Matthias Clasen
21d98dbc4b improve completion test coverage 2010-08-03 10:25:54 -04:00
Matthias Clasen
e4b5104003 Move bookmarkfile tests to the test framework 2010-08-03 10:25:54 -04:00
Matthias Clasen
03be0d7237 Move markup parse tests to the test framework 2010-07-30 19:51:21 -04:00
Matthias Clasen
13ac9f94fd Add some more GFile tests 2010-07-30 19:51:19 -04:00
Matthias Clasen
c972d4df64 Move markup escape tests to test framework 2010-07-30 19:51:18 -04:00
Matthias Clasen
d0750c9d6e Don't leak in converter test 2010-07-30 19:51:18 -04:00
Matthias Clasen
9fc3c980cc Add some volume monitor tests
Although not much of this is easily testable.
2010-07-30 19:51:17 -04:00
Matthias Clasen
e5a72ae3c4 Move queue tests to the test framework 2010-07-30 19:51:17 -04:00
Olivier Crête
f6d3e224df notify: Add tests for threadsafe object notifies
https://bugzilla.gnome.org/show_bug.cgi?id=166020
2010-07-22 21:56:21 +02:00