Skip to content

Commit

Permalink
Merge pull request #15 from mfherman/master
Browse files Browse the repository at this point in the history
change all instances of aw_validate to ar_validate
  • Loading branch information
Christopher Prener authored Jan 18, 2019
2 parents 3443c8b + 75f1632 commit 2d4787e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion R/aw_preview_weights.R
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ aw_preview_weights <- function(.data, tid, source, sid, type){
# validate source and target data
if (aw_validate_preview(source = source, target = .data) == FALSE){

stop("Data validation failed. Use aw_validate with verbose = TRUE to identify concerns.")
stop("Data validation failed. Use ar_validate with verbose = TRUE to identify concerns.")

}

Expand Down
8 changes: 4 additions & 4 deletions tests/testthat/test_aw_preview_weights.R
Original file line number Diff line number Diff line change
Expand Up @@ -75,13 +75,13 @@ race83 <- sf::st_transform(ar_stl_race, crs = 4269)

test_that("validation result is false", {
expect_error(aw_preview_weights(wardsdf, tid = WARD, source = ar_stl_race, sid = GEOID, type = "extensive"),
"Data validation failed. Use aw_validate with verbose = TRUE to identify concerns.")
"Data validation failed. Use ar_validate with verbose = TRUE to identify concerns.")
expect_error(aw_preview_weights(ar_stl_wards, tid = WARD, source = racedf, sid = GEOID, type = "extensive"),
"Data validation failed. Use aw_validate with verbose = TRUE to identify concerns.")
"Data validation failed. Use ar_validate with verbose = TRUE to identify concerns.")
expect_error(aw_preview_weights(wards83, tid = WARD, source = ar_stl_race, sid = GEOID, type = "extensive"),
"Data validation failed. Use aw_validate with verbose = TRUE to identify concerns.")
"Data validation failed. Use ar_validate with verbose = TRUE to identify concerns.")
expect_error(aw_preview_weights(ar_stl_wards, tid = WARD, source = race83, sid = GEOID, type = "extensive"),
"Data validation failed. Use aw_validate with verbose = TRUE to identify concerns.")
"Data validation failed. Use ar_validate with verbose = TRUE to identify concerns.")
})

# test output ------------------------------------------------
Expand Down

0 comments on commit 2d4787e

Please sign in to comment.