Skip to content

Commit

Permalink
version 1.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
ginberg committed Nov 7, 2023
1 parent 7851ab7 commit ae94b25
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 6 deletions.
6 changes: 3 additions & 3 deletions CRAN-SUBMISSION
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
Version: 0.4.6
Date: 2023-08-16 13:20:11 UTC
SHA: 5bbdbdb4d813b2d122933029be67b91a5a9ef811
Version: 1.0.1
Date: 2023-11-06 07:37:15 UTC
SHA: dc2612c5ca69955ea95e295703e67377b608870a
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: DrugExposureDiagnostics
Title: Diagnostics for OMOP Common Data Model Drug Records
Version: 1.0.0
Version: 1.0.1
Authors@R: c(
person("Ger", "Inberg", email = "g.inberg@erasmusmc.nl", role = c("aut", "cre"),
comment = c(ORCID = "0000-0001-8993-8748")),
Expand Down
3 changes: 3 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# DrugExposureDiagnostics (development version)

# DrugExposureDiagnostics 1.0.1
* Fix unit test

# DrugExposureDiagnostics 1.0.0
* Obscure patient counts in concept/diagnostics summary
* Update documentation regarding default checks
Expand Down
1 change: 1 addition & 0 deletions R/getDrugRecords.R
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ getDrugRecords <- function(cdm,
verbose = FALSE) {
errorMessage <- checkmate::makeAssertCollection()
checkDbType(cdm = cdm, messageStore = errorMessage)
checkmate::assertNumeric(ingredient, add = errorMessage)
checkTableExists(
cdm = cdm, tableName = includedConceptsTable,
messageStore = errorMessage
Expand Down
4 changes: 2 additions & 2 deletions tests/testthat/test-GetDrugRecords.R
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ getTestData <- function(ingredientId) {
}

test_that("getDrugRecords", {
ingredientId <- "1125315"
ingredientId <- 1125315
cdm <- getTestData(ingredientId)
result <- getDrugRecords(cdm = cdm, ingredient = ingredientId, includedConceptsTable = "ingredient_concepts") %>%
dplyr::collect()
Expand All @@ -63,7 +63,7 @@ test_that("getDrugRecords", {
"ingredient"))

# non exising ingredient should deliver no results
result <- getDrugRecords(cdm = cdm, ingredient = "123456", includedConceptsTable = "ingredient_concepts") %>%
result <- getDrugRecords(cdm = cdm, ingredient = 123456, includedConceptsTable = "ingredient_concepts") %>%
dplyr::collect()
expect_equal(nrow(result), 0)
})
Expand Down

0 comments on commit ae94b25

Please sign in to comment.