diff --git a/test-fixtures/test-utils.c b/test-fixtures/test-utils.c index 5980eeb54..b85efcded 100644 --- a/test-fixtures/test-utils.c +++ b/test-fixtures/test-utils.c @@ -145,6 +145,9 @@ test_utils_init (TestFlags requirement_flags, is_boolean_env_set ("V")) cogl_test_is_verbose = TRUE; + /* NB: This doesn't have any effect since commit 47444dac of glib + * because the environment variable is read in a magic constructor + * so it is too late to set them here */ if (g_getenv ("G_DEBUG")) { char *debug = g_strconcat (g_getenv ("G_DEBUG"), ",fatal-warnings", NULL); diff --git a/tests/run-tests.sh b/tests/run-tests.sh index a00494338..388fa036c 100755 --- a/tests/run-tests.sh +++ b/tests/run-tests.sh @@ -1,5 +1,13 @@ #!/bin/bash +if test -z "$G_DEBUG"; then + G_DEBUG=fatal-warnings +else + G_DEBUG="$G_DEBUG,fatal-warnings" +fi + +export G_DEBUG + ENVIRONMENT_CONFIG=$1 shift