tests/testthat/test-columns.R

context("columns")

test_that("get_dd_cols returns correct columns", {
  cols <- c(
    "Variable / Field Name",
    "Form Name",
    "Section Header",
    "Field Type",
    "Field Label",
    "Choices, Calculations, OR Slider Labels",
    "Field Note",
    "Text Validation Type OR Show Slider Number",
    "Text Validation Min",
    "Text Validation Max",
    "Identifier?",
    "Branching Logic (Show field only if...)",
    "Required Field?",
    "Custom Alignment",
    "Question Number (surveys only)",
    "Matrix Group Name",
    "Matrix Ranking?",
    "Field Annotation"
  )

  expect_equal(cols, get_dd_cols())
})
Sage-Bionetworks/redcapdd documentation built on May 17, 2019, 6:34 p.m.