From 93478c670b214ce1bb9cd6fcee7e43ed909e79cf Mon Sep 17 00:00:00 2001 From: siddhesh195 Date: Mon, 5 Aug 2024 08:47:07 -0400 Subject: [PATCH] changed names in list --- tests/testthat/test-renderer1-knit-print.R | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/tests/testthat/test-renderer1-knit-print.R b/tests/testthat/test-renderer1-knit-print.R index a2fbe494..7a024777 100644 --- a/tests/testthat/test-renderer1-knit-print.R +++ b/tests/testthat/test-renderer1-knit-print.R @@ -84,8 +84,8 @@ get_elements <- function(id){ legend_show_hide <- runtime_evaluate_helper(id=id,class_name='table.legend tr.label_variable',list_num=0,return.value=TRUE) legend_widget <- runtime_evaluate_helper(id=id,class_name='table.legend tr.label_variable',list_num=1,return.value=TRUE) - list(a178=top_widget_show_hide, - b934=bottom_widget_show_hide, + list(top_widget_show_hide=top_widget_show_hide, + bottom_widget_show_hide=bottom_widget_show_hide, show_hide=legend_show_hide, widget=legend_widget) } @@ -98,32 +98,32 @@ plot1bottom <- get_elements("plot1bottom") test_that("clicking top legend adds/remove points", { expect_equal(get_circles(), list(10, 10)) - clickID("plot1top_q_label_variable_a178") + clickID("plot1top_q_label_variable_top_widget_show_hide") expect_equal(get_circles(), list(5, 10)) - clickID("plot1top_q_label_variable_b934") + clickID("plot1top_q_label_variable_bottom_widget_show_hide") expect_equal(get_circles(), list(0, 10)) - clickID("plot1top_q_label_variable_b934") + clickID("plot1top_q_label_variable_bottom_widget_show_hide") expect_equal(get_circles(), list(5, 10)) - clickID("plot1top_q_label_variable_a178") + clickID("plot1top_q_label_variable_top_widget_show_hide") expect_equal(get_circles(), list(10, 10)) }) test_that("clicking bottom legend adds/remove points", { expect_equal(get_circles(), list(10, 10)) - clickID("plot1bottom_q_label_variable_a178") + clickID("plot1bottom_q_label_variable_top_widget_show_hide") expect_equal(get_circles(), list(10, 5)) - clickID("plot1bottom_q_label_variable_b934") + clickID("plot1bottom_q_label_variable_bottom_widget_show_hide") expect_equal(get_circles(), list(10, 0)) - clickID("plot1bottom_q_label_variable_b934") + clickID("plot1bottom_q_label_variable_bottom_widget_show_hide") expect_equal(get_circles(), list(10, 5)) - clickID("plot1bottom_q_label_variable_a178") + clickID("plot1bottom_q_label_variable_top_widget_show_hide") expect_equal(get_circles(), list(10, 10)) }) clickSide<- function(position=NULL){