[gtk+] tests: Add a uint8 test
- From: Benjamin Otte <otte src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] tests: Add a uint8 test
- Date: Mon, 9 Apr 2012 01:10:24 +0000 (UTC)
commit 122cde95284f94afc39fa934c4e145a03105fda8
Author: Benjamin Otte <otte redhat com>
Date: Mon Apr 9 02:54:17 2012 +0200
tests: Add a uint8 test
... to ensure the last test works.
tests/css/parser/test-css-parser.c | 15 +++++++++++++++
1 files changed, 15 insertions(+), 0 deletions(-)
---
diff --git a/tests/css/parser/test-css-parser.c b/tests/css/parser/test-css-parser.c
index feea8a5..ebe2b2b 100644
--- a/tests/css/parser/test-css-parser.c
+++ b/tests/css/parser/test-css-parser.c
@@ -287,6 +287,15 @@ add_tests_for_files_in_directory (GFile *dir)
g_list_free_full (files, g_object_unref);
}
+static gboolean
+parse_uint8 (const char *string,
+ GValue *value,
+ GError **error)
+{
+ g_value_set_uchar (value, 42);
+ return TRUE;
+}
+
int
main (int argc, char **argv)
{
@@ -382,6 +391,12 @@ main (int argc, char **argv)
GTK_TYPE_STATE_FLAGS,
GTK_STATE_FLAG_NORMAL,
G_PARAM_READABLE));
+ gtk_style_properties_register_property (parse_uint8,
+ g_param_spec_uchar ("uint8-property",
+ "uint8 property",
+ "test uint8 properties",
+ 0, G_MAXUINT8, 0,
+ G_PARAM_READABLE));
if (argc < 2)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]