# WARNING - Generated by {fusen} from dev/flat_detect_chars_structure.Rmd: do not edit by hand

test_that("Valid outputs are consistent", {
  expect_true(detect_chars_structure(
  vector = c("ABCD1234", "4567EF", "89GHIJ10"), 
  patterns = "[:alpha:]{4}"))
  
  expect_equal(
    detect_chars_structure(
      vector = c("ABCD1234", "4567EF", "89GHIJ10"), 
      patterns = "[:alpha:]{4}", 
    verbose = TRUE),
    list(`Any defined structure` = TRUE, Which = c("ABCD1234", "89GHIJ10"
    ), Where = c(1L, 3L))
  )})

test_that("Errors are consistent", {
  
  expect_error(
    detect_chars_structure(
      vector = c(1:4), 
      patterns = "[:digit:]{1}"),
    regexp = "vector must be of type character")
})
