diff options
Diffstat (limited to 'tests/at-spi2-atk/atk_test_table_cell.c')
-rw-r--r-- | tests/at-spi2-atk/atk_test_table_cell.c | 70 |
1 files changed, 32 insertions, 38 deletions
diff --git a/tests/at-spi2-atk/atk_test_table_cell.c b/tests/at-spi2-atk/atk_test_table_cell.c index efb35eab..463f1a16 100644 --- a/tests/at-spi2-atk/atk_test_table_cell.c +++ b/tests/at-spi2-atk/atk_test_table_cell.c @@ -24,9 +24,9 @@ #define DATA_FILE TESTS_DATA_DIR "/test-table.xml" static void -atk_test_accessible_get_table_cell (gpointer fixture, gconstpointer user_data) +atk_test_accessible_get_table_cell (TestAppFixture *fixture, gconstpointer user_data) { - AtspiAccessible *_obj = get_root_obj (DATA_FILE); + AtspiAccessible *_obj = fixture->root_obj; g_assert (_obj); AtspiAccessible *child = atspi_accessible_get_child_at_index (_obj, 0, NULL); g_assert (child); @@ -37,9 +37,9 @@ atk_test_accessible_get_table_cell (gpointer fixture, gconstpointer user_data) } static void -atk_test_table_cell_get_column_span (gpointer fixture, gconstpointer user_data) +atk_test_table_cell_get_column_span (TestAppFixture *fixture, gconstpointer user_data) { - AtspiAccessible *_obj = get_root_obj (DATA_FILE); + AtspiAccessible *_obj = fixture->root_obj; g_assert (_obj); AtspiAccessible *child = atspi_accessible_get_child_at_index (_obj, 0, NULL); g_assert (child); @@ -59,9 +59,9 @@ atk_test_table_cell_get_column_span (gpointer fixture, gconstpointer user_data) /* static void -atk_test_table_cell_get_column_header_cells (gpointer fixture, gconstpointer user_data) +atk_test_table_cell_get_column_header_cells (TestAppFixture *fixture, gconstpointer user_data) { - AtspiAccessible *_obj = get_root_obj (DATA_FILE); + AtspiAccessible *_obj = fixture->root_obj; g_assert (_obj); AtspiAccessible *child = atspi_accessible_get_child_at_index (_obj, 0, NULL); g_assert (child); @@ -76,9 +76,9 @@ atk_test_table_cell_get_column_header_cells (gpointer fixture, gconstpointer use */ static void -atk_test_table_cell_get_row_span (gpointer fixture, gconstpointer user_data) +atk_test_table_cell_get_row_span (TestAppFixture *fixture, gconstpointer user_data) { - AtspiAccessible *_obj = get_root_obj (DATA_FILE); + AtspiAccessible *_obj = fixture->root_obj; g_assert (_obj); AtspiAccessible *child = atspi_accessible_get_child_at_index (_obj, 0, NULL); g_assert (child); @@ -98,9 +98,9 @@ atk_test_table_cell_get_row_span (gpointer fixture, gconstpointer user_data) /* static void -atk_test_table_cell_get_row_header_cells (gpointer fixture, gconstpointer user_data) +atk_test_table_cell_get_row_header_cells (TestAppFixture *fixture, gconstpointer user_data) { - AtspiAccessible *_obj = get_root_obj (DATA_FILE); + AtspiAccessible *_obj = fixture->root_obj; g_assert (_obj); AtspiAccessible *child = atspi_accessible_get_child_at_index (_obj, 0, NULL); g_assert (child); @@ -115,9 +115,9 @@ atk_test_table_cell_get_row_header_cells (gpointer fixture, gconstpointer user_d */ static void -atk_test_table_cell_get_row_column_span (gpointer fixture, gconstpointer user_data) +atk_test_table_cell_get_row_column_span (TestAppFixture *fixture, gconstpointer user_data) { - AtspiAccessible *_obj = get_root_obj (DATA_FILE); + AtspiAccessible *_obj = fixture->root_obj; g_assert (_obj); AtspiAccessible *child = atspi_accessible_get_child_at_index (_obj, 0, NULL); g_assert (child); @@ -140,9 +140,9 @@ atk_test_table_cell_get_row_column_span (gpointer fixture, gconstpointer user_da } static void -atk_test_table_cell_get_position (gpointer fixture, gconstpointer user_data) +atk_test_table_cell_get_position (TestAppFixture *fixture, gconstpointer user_data) { - AtspiAccessible *_obj = get_root_obj (DATA_FILE); + AtspiAccessible *_obj = fixture->root_obj; g_assert (_obj); AtspiAccessible *child = atspi_accessible_get_child_at_index (_obj, 0, NULL); g_assert (child); @@ -162,9 +162,9 @@ atk_test_table_cell_get_position (gpointer fixture, gconstpointer user_data) } static void -atk_test_table_cell_get_table (gpointer fixture, gconstpointer user_data) +atk_test_table_cell_get_table (TestAppFixture *fixture, gconstpointer user_data) { - AtspiAccessible *_obj = get_root_obj (DATA_FILE); + AtspiAccessible *_obj = fixture->root_obj; g_assert (_obj); AtspiAccessible *child = atspi_accessible_get_child_at_index (_obj, 0, NULL); g_assert (child); @@ -178,33 +178,27 @@ atk_test_table_cell_get_table (gpointer fixture, gconstpointer user_data) g_assert (child == tab); } -static void -teardown_table_cell_test (gpointer fixture, gconstpointer user_data) -{ - terminate_app (); -} - void atk_test_table_cell (void) { - g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_accessible_get_table_cell", - 0, NULL, NULL, atk_test_accessible_get_table_cell, teardown_table_cell_test); - g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_column_span", - 0, NULL, NULL, atk_test_table_cell_get_column_span, teardown_table_cell_test); + g_test_add ("/table_cell/atk_test_accessible_get_table_cell", + TestAppFixture, DATA_FILE, fixture_setup, atk_test_accessible_get_table_cell, fixture_teardown); + g_test_add ("/table_cell/atk_test_table_cell_get_column_span", + TestAppFixture, DATA_FILE, fixture_setup, atk_test_table_cell_get_column_span, fixture_teardown); /* - g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_column_header_cells", - 0, NULL, NULL, atk_test_table_cell_get_column_header_cells, teardown_table_cell_test); + g_test_add ("/table_cell/atk_test_table_cell_get_column_header_cells", + TestAppFixture, DATA_FILE, fixture_setup, atk_test_table_cell_get_column_header_cells, fixture_teardown); */ - g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_row_span", - 0, NULL, NULL, atk_test_table_cell_get_row_span, teardown_table_cell_test); + g_test_add ("/table_cell/atk_test_table_cell_get_row_span", + TestAppFixture, DATA_FILE, fixture_setup, atk_test_table_cell_get_row_span, fixture_teardown); /* - g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_row_header_cells", - 0, NULL, NULL, atk_test_table_cell_get_row_header_cells, teardown_table_cell_test); + g_test_add ("/table_cell/atk_test_table_cell_get_row_header_cells", + TestAppFixture, DATA_FILE, fixture_setup, atk_test_table_cell_get_row_header_cells, fixture_teardown); */ - g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_row_column_span", - 0, NULL, NULL, atk_test_table_cell_get_row_column_span, teardown_table_cell_test); - g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_position", - 0, NULL, NULL, atk_test_table_cell_get_position, teardown_table_cell_test); - g_test_add_vtable (ATK_TEST_PATH_TABLE_CELL "/atk_test_table_cell_get_table", - 0, NULL, NULL, atk_test_table_cell_get_table, teardown_table_cell_test); + g_test_add ("/table_cell/atk_test_table_cell_get_row_column_span", + TestAppFixture, DATA_FILE, fixture_setup, atk_test_table_cell_get_row_column_span, fixture_teardown); + g_test_add ("/table_cell/atk_test_table_cell_get_position", + TestAppFixture, DATA_FILE, fixture_setup, atk_test_table_cell_get_position, fixture_teardown); + g_test_add ("/table_cell/atk_test_table_cell_get_table", + TestAppFixture, DATA_FILE, fixture_setup, atk_test_table_cell_get_table, fixture_teardown); } |