Tests
3 unresolved threads
3 unresolved threads
Implementation of "thesthat" tests
Merge request reports
Activity
added Ready for review label
added 4 commits
-
3aaaed04...a3db7236 - 2 commits from branch
master
- 4e73a643 - Merge master
- 44408674 - Started updating tests
-
3aaaed04...a3db7236 - 2 commits from branch
added 1 commit
- 267f4e90 - added sample text and image file, changed tests
- tests/testthat/test-add-content.R 0 → 100644
81 expect_equal(base_component("input-data/sample.jpg")@pages$default$components[[1]], "### Test\n\n\n") 82 83 # test signature 'i2dashboard,gg' 84 o1 <- ggplot2::ggplot(mtcars,ggplot2::aes(x=wt,y=mpg)) + ggplot2::geom_point() 85 86 expect_equal(length(base_component(o1)@pages$default$components), 1) 87 expect_match(base_component(o1)@pages$default$components[[1]], "### Test") 88 89 # test signature 'i2dashboard,gt_tbl' 90 o2 <- gt::gt(mtcars) 91 92 expect_equal(length(base_component(o2)@pages$default$components), 1) 93 expect_match(base_component(o2)@pages$default$components[[1]], "### Test") 94 95 # test signature 'i2dashboard,knitr_kable' 96 o3 <- kableExtra::kable(mtcars) %>% kableExtra::kable_styling() changed this line in version 4 of the diff
- tests/testthat/test-internal-functions.R 0 → 100644
1 context("Internal functions") 2 3 # 4 # add_vis_object 5 # 6 test_that("add_vis_object works correctly",{ 7 obj <- plotly::plot_ly(mtcars,x=~wt,y=~mpg) changed this line in version 4 of the diff
- tests/testthat/test-internal-functions.R 0 → 100644
33 # render_text 34 # 35 test_that("render_text works correctly",{ 36 expect_equal(i2dash:::render_text("input-data/sample.txt"), "### \n\nLorem ipsum dolor sit amet\n") 37 }) 38 39 # 40 # .add_component 41 # 42 test_that(".add_component works correctly",{ 43 comp <- "### Component\n\nContent\n\n" 44 i2dashboard() %>% i2dash:::.add_component("default", comp) -> dashboard 45 46 expect_equal(length(dashboard@pages$default$components), 1) 47 expect_match(dashboard@pages$default$components[[1]], "### Component\n\nContent\n\n") 48 unlink(dashboard@datadir, recursive=TRUE) changed this line in version 4 of the diff
added 14 commits
-
2e7968ae...bc563373 - 12 commits from branch
master
- b6b596d0 - Merge branch 'master' into tests
- 8d13a160 - changed tests of add_to_sidebar();
-
2e7968ae...bc563373 - 12 commits from branch
mentioned in commit 013c9fe5
Please register or sign in to reply