gboolean urgent);
typedef DBusMessage *(*get_inkey_cb_t)(DBusMessage *msg, const char *alpha,
unsigned char icon_id);
+typedef DBusMessage *(*get_input_cb_t)(DBusMessage *msg, const char *alpha,
+ unsigned char icon_id,
+ const char *def_input,
+ unsigned char min_chars,
+ unsigned char max_chars,
+ gboolean hide_typing);
typedef void (*terminal_response_func)(const unsigned char *pdu,
unsigned int len);
func = test->agent_func; \
\
if (strcmp(test->method, method_name)) { \
- g_printerr("Wrong method called!\n"); \
+ g_printerr("Wrong method called!" \
+ " Expected: %s, Got: %s\n", \
+ test->method, method_name); \
__stktest_test_finish(FALSE); \
return stktest_error_failed(msg); \
} \
GET_INKEY_TEMPLATE(agent_request_digit, "RequestDigit")
GET_INKEY_TEMPLATE(agent_request_confirmation, "RequestConfirmation")
+#define GET_INPUT_TEMPLATE(func, method_name) \
+static DBusMessage *func(DBusConnection *conn, DBusMessage *msg, \
+ void *data) \
+{ \
+ const char *alpha; \
+ const char *def_input; \
+ unsigned char icon_id; \
+ unsigned char min_chars; \
+ unsigned char max_chars; \
+ gboolean hide_typing; \
+ struct test *test; \
+ get_input_cb_t func; \
+ DBusMessage *reply; \
+ \
+ if (dbus_message_get_args(msg, NULL, DBUS_TYPE_STRING, &alpha, \
+ DBUS_TYPE_BYTE, &icon_id, \
+ DBUS_TYPE_STRING, &def_input, \
+ DBUS_TYPE_BYTE, &min_chars, \
+ DBUS_TYPE_BYTE, &max_chars, \
+ DBUS_TYPE_BOOLEAN, \
+ &hide_typing, \
+ DBUS_TYPE_INVALID) == FALSE) \
+ return stktest_error_invalid_args(msg); \
+ \
+ if (cur_test == NULL) \
+ return stktest_error_failed(msg); \
+ \
+ test = cur_test->data; \
+ func = test->agent_func; \
+ \
+ if (strcmp(test->method, method_name)) { \
+ g_printerr("Wrong method called!" \
+ " Expected: %s, Got: %s\n", \
+ test->method, method_name); \
+ __stktest_test_finish(FALSE); \
+ return stktest_error_failed(msg); \
+ } \
+ \
+ if (func == NULL) { \
+ g_printerr(method_name " not expected to be called"); \
+ __stktest_test_finish(FALSE); \
+ return stktest_error_failed(msg); \
+ } \
+ \
+ reply = func(msg, alpha, icon_id, def_input, \
+ min_chars, max_chars, hide_typing); \
+ if (reply == NULL) \
+ pending = dbus_message_ref(msg); \
+ \
+ return reply; \
+} \
+
+GET_INPUT_TEMPLATE(agent_request_input, "RequestInput")
+GET_INPUT_TEMPLATE(agent_request_digits, "RequestDigits")
+
static void server_debug(const char *str, void *data)
{
g_print("%s: %s\n", (char *) data, str);
GDBUS_ARGS({ "alpha", "s" }, { "icon_id", "y" }),
GDBUS_ARGS({ "confirmation", "b" }),
agent_request_confirmation) },
+ { GDBUS_ASYNC_METHOD("RequestInput",
+ GDBUS_ARGS({ "alpha", "s" }, { "icon_id", "y" },
+ { "default", "s" }, { "min_chars", "y" },
+ { "max_chars", "y" }, { "hide_typing", "b" }),
+ GDBUS_ARGS({ "input", "s" }), agent_request_input) },
+ { GDBUS_ASYNC_METHOD("RequestDigits",
+ GDBUS_ARGS({ "alpha", "s" }, { "icon_id", "y" },
+ { "default", "s" }, { "min_chars", "y" },
+ { "max_chars", "y" }, { "hide_typing", "b" }),
+ GDBUS_ARGS({ "digits", "s" }), agent_request_digits) },
{ GDBUS_NOREPLY_METHOD("Cancel", NULL, NULL, agent_cancel) },
{ },
};
const char *alpha,
unsigned char icon_id)
{
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, "Enter \"+\""));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ return NULL;
+}
+
+static DBusMessage *test_get_inkey_91(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
DBusMessage *reply;
const char *ret = "+";
+ const char *expect =
+ "<div style=\"text-align: left;\"><span style=\"color: "
+ "#347235;background-color: #FFFF00;\">Enter \"+\"</span></div>";
- STKTEST_AGENT_ASSERT(g_str_equal(alpha, "Enter \"+\""));
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
STKTEST_AGENT_ASSERT(icon_id == 0);
- return NULL;
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_92(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect =
+ "<div style=\"text-align: center;\"><span style=\"color: "
+ "#347235;background-color: #FFFF00;\">Enter \"+\"</span>"
+ "</div>";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_93(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect =
+ "<div style=\"text-align: right;\"><span style=\"color: "
+ "#347235;background-color: #FFFF00;\">Enter \"+\"</span>"
+ "</div>";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_94(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect =
+ "<div style=\"text-align: left;\"><span style=\"font-size: "
+ "big;color: #347235;background-color: #FFFF00;\">Enter \"+\""
+ "</span></div>";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_95(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect =
+ "<div style=\"text-align: left;\"><span style=\"font-size: "
+ "small;color: #347235;background-color: #FFFF00;\">"
+ "Enter \"+\"</span></div>";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_96(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect =
+ "<div style=\"text-align: left;\"><span style=\"font-weight: "
+ "bold;color: #347235;background-color: #FFFF00;\">Enter \"+\""
+ "</span></div>";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_97(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect =
+ "<div style=\"text-align: left;\"><span style=\"font-style: "
+ "italic;color: #347235;background-color: #FFFF00;\">"
+ "Enter \"+\"</span></div>";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_98(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect =
+ "<div style=\"text-align: left;\"><span style=\""
+ "text-decoration: underline;color: #347235;"
+ "background-color: #FFFF00;\">Enter \"+\"</span></div>";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_99(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect =
+ "<div style=\"text-align: left;\"><span style=\""
+ "text-decoration: line-through;color: #347235;"
+ "background-color: #FFFF00;\">Enter \"+\"</span></div>";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_910(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect =
+ "<div style=\"text-align: left;\"><span style=\"color: "
+ "#347235;background-color: #FFFF00;\">Enter \"+\"</span></div>";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_101(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect = "你好";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_102(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect =
+ "你好你好你好你好你好你好你好你好你好你好"
+ "你好你好你好你好你好你好你好你好你好你好"
+ "你好你好你好你好你好你好你好你好你好你好"
+ "你好你好你好你好你好";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_111(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "好";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, "Enter"));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_121(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect = "ル";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_122(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "+";
+ const char *expect =
+ "ルルルルルルルルルルルルルルルルルルルル"
+ "ルルルルルルルルルルルルルルルルルルルル"
+ "ルルルルルルルルルルルルルルルルルルルル"
+ "ルルルルルルルルルル";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, expect));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_inkey_131(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id)
+{
+ DBusMessage *reply;
+ const char *ret = "ル";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, "Enter"));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_input_11(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id,
+ const char *def_input,
+ unsigned char min, unsigned char max,
+ gboolean hide_typing)
+{
+ DBusMessage *reply;
+ const char *ret = "12345";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, "Enter 12345"));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+ STKTEST_AGENT_ASSERT(g_str_equal(def_input, ""));
+ STKTEST_AGENT_ASSERT(min == 5);
+ STKTEST_AGENT_ASSERT(max == 5);
+ STKTEST_AGENT_ASSERT(hide_typing == FALSE);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_input_12(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id,
+ const char *def_input,
+ unsigned char min, unsigned char max,
+ gboolean hide_typing)
+{
+ DBusMessage *reply;
+ const char *ret = "67*#+";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, "Enter 67*#+"));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+ STKTEST_AGENT_ASSERT(g_str_equal(def_input, ""));
+ STKTEST_AGENT_ASSERT(min == 5);
+ STKTEST_AGENT_ASSERT(max == 5);
+ STKTEST_AGENT_ASSERT(hide_typing == FALSE);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_input_13(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id,
+ const char *def_input,
+ unsigned char min, unsigned char max,
+ gboolean hide_typing)
+{
+ DBusMessage *reply;
+ const char *ret = "AbCdE";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha, "Enter AbCdE"));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+ STKTEST_AGENT_ASSERT(g_str_equal(def_input, ""));
+ STKTEST_AGENT_ASSERT(min == 5);
+ STKTEST_AGENT_ASSERT(max == 5);
+ STKTEST_AGENT_ASSERT(hide_typing == FALSE);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_input_14(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id,
+ const char *def_input,
+ unsigned char min, unsigned char max,
+ gboolean hide_typing)
+{
+ DBusMessage *reply;
+ const char *ret = "2345678";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha,
+ "Password 1<SEND>2345678"));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+ STKTEST_AGENT_ASSERT(g_str_equal(def_input, ""));
+ STKTEST_AGENT_ASSERT(min == 4);
+ STKTEST_AGENT_ASSERT(max == 8);
+ STKTEST_AGENT_ASSERT(hide_typing == TRUE);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
+}
+
+static DBusMessage *test_get_input_15(DBusMessage *msg,
+ const char *alpha,
+ unsigned char icon_id,
+ const char *def_input,
+ unsigned char min, unsigned char max,
+ gboolean hide_typing)
+{
+ DBusMessage *reply;
+ const char *ret = "12345678901234567890";
+
+ STKTEST_AGENT_ASSERT(g_str_equal(alpha,
+ "Enter 1..9,0..9,0(1)"));
+ STKTEST_AGENT_ASSERT(icon_id == 0);
+ STKTEST_AGENT_ASSERT(g_str_equal(def_input, ""));
+ STKTEST_AGENT_ASSERT(min == 1);
+ STKTEST_AGENT_ASSERT(max == 20);
+ STKTEST_AGENT_ASSERT(hide_typing == FALSE);
+
+ reply = dbus_message_new_method_return(msg);
+ dbus_message_append_args(reply, DBUS_TYPE_STRING, &ret,
+ DBUS_TYPE_INVALID);
+
+ return reply;
}
static void power_down_reply(DBusPendingCall *call, void *user_data)
sizeof(get_inkey_response_811),
test_get_inkey_81,
expect_response_and_finish);
+ stktest_add_test("Get Inkey 9.1", "RequestDigit",
+ get_inkey_911, sizeof(get_inkey_911),
+ get_inkey_response_911,
+ sizeof(get_inkey_response_911),
+ test_get_inkey_91,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 9.2", "RequestDigit",
+ get_inkey_921, sizeof(get_inkey_921),
+ get_inkey_response_921,
+ sizeof(get_inkey_response_921),
+ test_get_inkey_92,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 9.3", "RequestDigit",
+ get_inkey_931, sizeof(get_inkey_931),
+ get_inkey_response_931,
+ sizeof(get_inkey_response_931),
+ test_get_inkey_93,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 9.4", "RequestDigit",
+ get_inkey_941, sizeof(get_inkey_941),
+ get_inkey_response_941,
+ sizeof(get_inkey_response_941),
+ test_get_inkey_94,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 9.5", "RequestDigit",
+ get_inkey_951, sizeof(get_inkey_951),
+ get_inkey_response_951,
+ sizeof(get_inkey_response_951),
+ test_get_inkey_95,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 9.6", "RequestDigit",
+ get_inkey_961, sizeof(get_inkey_961),
+ get_inkey_response_961,
+ sizeof(get_inkey_response_961),
+ test_get_inkey_96,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 9.7", "RequestDigit",
+ get_inkey_971, sizeof(get_inkey_971),
+ get_inkey_response_971,
+ sizeof(get_inkey_response_971),
+ test_get_inkey_97,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 9.8", "RequestDigit",
+ get_inkey_981, sizeof(get_inkey_981),
+ get_inkey_response_981,
+ sizeof(get_inkey_response_981),
+ test_get_inkey_98,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 9.9", "RequestDigit",
+ get_inkey_991, sizeof(get_inkey_991),
+ get_inkey_response_991,
+ sizeof(get_inkey_response_991),
+ test_get_inkey_99,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 9.10", "RequestDigit",
+ get_inkey_9101, sizeof(get_inkey_9101),
+ get_inkey_response_9101,
+ sizeof(get_inkey_response_9101),
+ test_get_inkey_910,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 10.1", "RequestDigit",
+ get_inkey_1011, sizeof(get_inkey_1011),
+ get_inkey_response_1011,
+ sizeof(get_inkey_response_1011),
+ test_get_inkey_101,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 10.2", "RequestDigit",
+ get_inkey_1021, sizeof(get_inkey_1021),
+ get_inkey_response_1021,
+ sizeof(get_inkey_response_1021),
+ test_get_inkey_102,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 11.1", "RequestKey",
+ get_inkey_1111, sizeof(get_inkey_1111),
+ get_inkey_response_1111,
+ sizeof(get_inkey_response_1111),
+ test_get_inkey_111,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 12.1", "RequestDigit",
+ get_inkey_1211, sizeof(get_inkey_1211),
+ get_inkey_response_1211,
+ sizeof(get_inkey_response_1211),
+ test_get_inkey_121,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 12.2", "RequestDigit",
+ get_inkey_1221, sizeof(get_inkey_1221),
+ get_inkey_response_1221,
+ sizeof(get_inkey_response_1221),
+ test_get_inkey_122,
+ expect_response_and_finish);
+ stktest_add_test("Get Inkey 13.1", "RequestKey",
+ get_inkey_1311, sizeof(get_inkey_1311),
+ get_inkey_response_1311,
+ sizeof(get_inkey_response_1311),
+ test_get_inkey_131,
+ expect_response_and_finish);
+ stktest_add_test("Get Input 1.1", "RequestDigits",
+ get_input_111, sizeof(get_input_111),
+ get_input_response_111,
+ sizeof(get_input_response_111),
+ test_get_input_11,
+ expect_response_and_finish);
+ stktest_add_test("Get Input 1.2", "RequestDigits",
+ get_input_121, sizeof(get_input_121),
+ get_input_response_121,
+ sizeof(get_input_response_121),
+ test_get_input_12,
+ expect_response_and_finish);
+ stktest_add_test("Get Input 1.3", "RequestInput",
+ get_input_131, sizeof(get_input_131),
+ get_input_response_131,
+ sizeof(get_input_response_131),
+ test_get_input_13,
+ expect_response_and_finish);
+ stktest_add_test("Get Input 1.4", "RequestDigits",
+ get_input_141, sizeof(get_input_141),
+ get_input_response_141,
+ sizeof(get_input_response_141),
+ test_get_input_14,
+ expect_response_and_finish);
+ stktest_add_test("Get Input 1.5", "RequestDigits",
+ get_input_151, sizeof(get_input_151),
+ get_input_response_151,
+ sizeof(get_input_response_151),
+ test_get_input_15,
+ expect_response_and_finish);
}
static void test_destroy(gpointer user_data)