Skip to content

Print a nice error when test config includes non-existing optional tests. #126

@robertzk

Description

@robertzk
> test_project()
Error in test_environment_configuration(engine, config)[[value]] :
  subscript out of bounds
In package syberia: test_project()
In /Users/robertk/.R/.syberia/engines/github/syberia/modeling.sy/master/config/global/modeling/modeling.R:47: syberia::test_engine(...)
In package base: force(ignored_tests)
In package syberia: ignored_tests_from_config(engine, base, config)
In package base: file.path(base, value_from_config(engine, config, "ignored_tests") %||%      character(0))
In package syberia: value_from_config(engine, config, "ignored_tests") %||% character(0)
In package syberia: value_from_config(engine, config, "ignored_tests")

Error:
  subscript out of bounds

The result of running test_project() when optional_tests <- c("models") in config/environments/test.R but models does not exist.

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions