From d8ba750b6a6c070b8dcadd96944a096a52267fcf Mon Sep 17 00:00:00 2001 From: Paweł Zuzelski Date: Tue, 12 Jan 2010 14:16:54 +0100 Subject: better way to check WebKit version use webkit_major_version(), webkit_minor_version() and webkit_micro_version() functions to obtain webkit version instead of accessing WEBKIT_MAJOR_VERSION, WEBKIT_MINOR_VERSION and WEBKIT_MICRO_VERSION directly. WEBKIT_M*_VERSION are defined in header files included by uzbl code, so they contain WebKit version that uzbl was compiled against. webkit_m*_version() functions return WebKit version that is realy used at the moment. --- tests/test-expand.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tests') diff --git a/tests/test-expand.c b/tests/test-expand.c index ef07c80..01af401 100644 --- a/tests/test-expand.c +++ b/tests/test-expand.c @@ -72,11 +72,11 @@ test_useragent (void) { void test_WEBKIT_VERSION (void) { GString* expected = g_string_new(""); - g_string_append(expected, itos(WEBKIT_MAJOR_VERSION)); + g_string_append(expected, itos(webkit_major_version())); g_string_append(expected, " "); - g_string_append(expected, itos(WEBKIT_MINOR_VERSION)); + g_string_append(expected, itos(webkit_minor_version())); g_string_append(expected, " "); - g_string_append(expected, itos(WEBKIT_MICRO_VERSION)); + g_string_append(expected, itos(webkit_micro_version())); g_assert_cmpstr(expand("@WEBKIT_MAJOR @WEBKIT_MINOR @WEBKIT_MICRO", 0), ==, g_string_free(expected, FALSE)); } -- cgit v1.2.3