Skip to content

[Feature Request]: Make sure validate_input works with all shiny inputs #280

@gogonzo

Description

@gogonzo

Feature description

See test-shinytest2-validate_input.R in teal and make sure that following tests are covered. Objective of the tests is making sure that js function validateInput is able to find the container with the input value.

    var selector1 = '.shiny-input-container#' + inputId;
    var selector2 = '.shiny-input-container:has(#' + inputId + ')';

If any input is wrapped in other container, then validation message will not find relevant place for it to show the message. (i don't expect such scenario but we need to make sure)

testthat::test_that("e2e: validate_input validates sliderInput")
testthat::test_that("e2e: validate_input validates selectInput")
testthat::test_that("e2e: validate_input validates selectizeInput")
testthat::test_that("e2e: validate_input validates radioButtons")
testthat::test_that("e2e: validate_input validates checkboxGroupInput")
testthat::test_that("e2e: validate_input validates checkboxInput")
testthat::test_that("e2e: validate_input validates dateInput")
testthat::test_that("e2e: validate_input validates dateRangeInput")
testthat::test_that("e2e: validate_input validates pickerInput")

Code of Conduct

  • I agree to follow this project's Code of Conduct.

Contribution Guidelines

  • I agree to follow this project's Contribution Guidelines.

Security Policy

  • I agree to follow this project's Security Policy.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions