Lines Matching refs:ctx
27 test_file(struct xkb_context *ctx, const char *path_rel)
29 struct xkb_keymap *keymap = test_compile_file(ctx, path_rel);
41 struct xkb_context *ctx = test_get_context(0);
43 assert(test_file(ctx, "keymaps/basic.xkb"));
44 assert(test_file(ctx, "keymaps/comprehensive-plus-geom.xkb"));
45 assert(test_file(ctx, "keymaps/no-types.xkb"));
46 assert(test_file(ctx, "keymaps/quartz.xkb"));
47 assert(test_file(ctx, "keymaps/no-aliases.xkb"));
49 assert(!test_file(ctx, "keymaps/divide-by-zero.xkb"));
50 assert(!test_file(ctx, "keymaps/bad.xkb"));
51 assert(!test_file(ctx, "keymaps/syntax-error.xkb"));
52 assert(!test_file(ctx, "keymaps/syntax-error2.xkb"));
53 assert(!test_file(ctx, "does not exist"));
57 assert(!xkb_keymap_new_from_file(ctx, NULL, XKB_KEYMAP_FORMAT_TEXT_V1, 0));
58 assert(!xkb_keymap_new_from_file(ctx, stdin, 0, 0));
59 assert(!xkb_keymap_new_from_file(ctx, stdin, XKB_KEYMAP_USE_ORIGINAL_FORMAT, 0));
60 assert(!xkb_keymap_new_from_file(ctx, stdin, 1234, 0));
61 assert(!xkb_keymap_new_from_file(ctx, stdin, XKB_KEYMAP_FORMAT_TEXT_V1, -1));
62 assert(!xkb_keymap_new_from_file(ctx, stdin, XKB_KEYMAP_FORMAT_TEXT_V1, 1234));
64 xkb_context_unref(ctx);