diff options
author | Brendan Taylor <whateley@gmail.com> | 2011-02-17 13:09:50 -0700 |
---|---|---|
committer | Brendan Taylor <whateley@gmail.com> | 2011-02-17 13:09:50 -0700 |
commit | 67af28c8d147e35c91ea91b0ddf51680d9feb475 (patch) | |
tree | 697e96acc530fefdc6ab6189d95e23127cc127cc /tests | |
parent | b7a47b3f58e6fa05d56577ea6425d353a41ddb86 (diff) | |
parent | e3b04d3ae9fb6dfeff5e6099784586b54591814e (diff) |
Merge branch 'escaped_events' into experimental
Conflicts:
src/util.c
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test-command.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/test-command.c b/tests/test-command.c index 6d3d81e..55bf316 100644 --- a/tests/test-command.c +++ b/tests/test-command.c @@ -152,7 +152,7 @@ test_set_variable (struct EventFixture *ef, const void *data) { /* set a string */ parse_cmd_line("set useragent = Uzbl browser kthxbye!", NULL); - ASSERT_EVENT(ef, "VARIABLE_SET useragent str Uzbl browser kthxbye!"); + ASSERT_EVENT(ef, "VARIABLE_SET useragent str 'Uzbl browser kthxbye!'"); g_assert_cmpstr("Uzbl browser kthxbye!", ==, uzbl.net.useragent); /* set an int */ @@ -168,7 +168,7 @@ test_set_variable (struct EventFixture *ef, const void *data) { parse_cmd_line(g_string_free(cmd, FALSE), NULL); ev = g_string_new("EVENT [" INSTANCE_NAME "] VARIABLE_SET zoom_level float "); - g_string_append_printf(ev, "%f\n", 0.25); + g_string_append_printf(ev, "%.2f\n", 0.25); read_event(ef); g_assert_cmpstr(g_string_free(ev, FALSE), ==, ef->event_buffer); @@ -188,13 +188,13 @@ test_set_variable (struct EventFixture *ef, const void *data) { /* set a custom variable */ parse_cmd_line("set nonexistant_variable = Some Value", NULL); - ASSERT_EVENT(ef, "VARIABLE_SET nonexistant_variable str Some Value"); + ASSERT_EVENT(ef, "VARIABLE_SET nonexistant_variable str 'Some Value'"); uzbl_cmdprop *c = g_hash_table_lookup(uzbl.comm.proto_var, "nonexistant_variable"); g_assert_cmpstr("Some Value", ==, *c->ptr.s); /* set a custom variable with expansion */ parse_cmd_line("set an_expanded_variable = Test @(echo expansion)@", NULL); - ASSERT_EVENT(ef, "VARIABLE_SET an_expanded_variable str Test expansion"); + ASSERT_EVENT(ef, "VARIABLE_SET an_expanded_variable str 'Test expansion'"); c = g_hash_table_lookup(uzbl.comm.proto_var, "an_expanded_variable"); g_assert_cmpstr("Test expansion", ==, *c->ptr.s); } |