[mutter] unit-tests: Pass argc/argv directly to g_test_init
- From: Jonas Ådahl <jadahl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] unit-tests: Pass argc/argv directly to g_test_init
- Date: Wed, 25 Jan 2017 08:38:41 +0000 (UTC)
commit 28a8c714eadccf0b8dbc14efd5629c61d15bf227
Author: Jonas Ådahl <jadahl gmail com>
Date: Thu Jan 12 13:52:52 2017 +0800
unit-tests: Pass argc/argv directly to g_test_init
Don't let a dummy option context consume the arguments; just let the
GLib test suite do it. It'll handle the basic command line arguments
and allow doing things such as specifying what test to run.
https://bugzilla.gnome.org/show_bug.cgi?id=777732
src/tests/unit-tests.c | 14 --------------
1 files changed, 0 insertions(+), 14 deletions(-)
---
diff --git a/src/tests/unit-tests.c b/src/tests/unit-tests.c
index 7b7818c..c70a7b0 100644
--- a/src/tests/unit-tests.c
+++ b/src/tests/unit-tests.c
@@ -207,20 +207,6 @@ init_tests (int argc, char **argv)
int
main (int argc, char *argv[])
{
- GOptionContext *ctx;
- GError *error = NULL;
-
- ctx = g_option_context_new (NULL);
-
- if (!g_option_context_parse (ctx,
- &argc, &argv, &error))
- {
- g_printerr ("%s", error->message);
- return 1;
- }
-
- g_option_context_free (ctx);
-
init_tests (argc, argv);
meta_plugin_manager_load ("default");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]