ASSERT_OK(vconsole_convert_to_x11(&vc, x11_context_verify, &xc));
ASSERT_TRUE(x11_context_isempty(&xc));
+ log_info("/* test leading-dash keymap */");
+ ASSERT_OK(free_and_strdup(&vc.keymap, "-foo"));
+ ASSERT_ERROR(vconsole_convert_to_x11(&vc, x11_context_verify, &xc), EINVAL);
+ ASSERT_TRUE(x11_context_isempty(&xc));
+
log_info("/* test without variant, new mapping (es:) */");
ASSERT_OK(free_and_strdup(&vc.keymap, "es"));
ASSERT_OK(vconsole_convert_to_x11(&vc, x11_context_verify, &xc));
ASSERT_OK(x11_convert_to_vconsole(&xc, &vc));
ASSERT_TRUE(vc_context_isempty(&vc));
+ log_info("/* test leading-comma layout */");
+ ASSERT_OK(free_and_strdup(&xc.layout, ",us"));
+ ASSERT_ERROR(x11_convert_to_vconsole(&xc, &vc), EINVAL);
+ ASSERT_TRUE(vc_context_isempty(&vc));
+
log_info("/* test without variant, new mapping (es:) */");
ASSERT_OK(free_and_strdup(&xc.layout, "es"));
ASSERT_OK(x11_convert_to_vconsole(&xc, &vc));