-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #44 from laijasmine/main
Save as we iterate through awards
- Loading branch information
Showing
8 changed files
with
70 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,5 +2,5 @@ | |
.Rhistory | ||
.RData | ||
.Ruserdata | ||
|
||
*.csv | ||
*.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -24,7 +24,8 @@ test_that('we can send an initial correspondence', { | |
} | ||
|
||
db <- create_dummy_database() | ||
db <- create_ticket_and_send_initial_correspondence(db) | ||
|
||
db <- create_ticket_and_send_initial_correspondence(db, database_path = "inst/test_db.csv") | ||
|
||
ticket <- rt::rt_ticket_properties(db$rt_ticket) | ||
expect_equal(ticket$Requestors, '[email protected]') | ||
|
@@ -36,9 +37,9 @@ test_that('we can send an annual report correspondence', { | |
} | ||
|
||
db <- create_dummy_database() | ||
db <- create_ticket_and_send_initial_correspondence(db) | ||
db <- create_ticket_and_send_initial_correspondence(db, database_path = "inst/test_db.csv") | ||
db$contact_annual_report_next <- as.character(Sys.Date()) | ||
db <- send_annual_report_correspondence(db) | ||
db <- send_annual_report_correspondence(db, database_path = "inst/test_db.csv") | ||
|
||
expect_equal(db$contact_annual_report_next, db$contact_annual_report_previous) | ||
}) | ||
|
@@ -49,10 +50,10 @@ test_that('we can send a one month remaining correspondence',{ | |
} | ||
|
||
db <- create_dummy_database() | ||
db <- create_ticket_and_send_initial_correspondence(db) | ||
db <- create_ticket_and_send_initial_correspondence(db, database_path = "inst/test_db.csv") | ||
# Set expiration date to one month from now | ||
db$contact_1mo <- as.character(Sys.Date()) | ||
db <- send_one_month_remaining_correspondence(db) | ||
db <- send_one_month_remaining_correspondence(db, database_path = "inst/test_db.csv") | ||
|
||
expect_equal(db$contact_1mo, as.character(Sys.Date())) | ||
}) | ||
|
@@ -63,9 +64,9 @@ test_that('we can send an aon correspondence', { | |
} | ||
|
||
db <- create_dummy_database() | ||
db <- create_ticket_and_send_initial_correspondence(db) | ||
db <- create_ticket_and_send_initial_correspondence(db, database_path = "inst/test_db.csv") | ||
db$contact_aon_next <- as.character(Sys.Date()) | ||
db <- send_aon_correspondence(db) | ||
db <- send_aon_correspondence(db, database_path = "inst/test_db.csv") | ||
|
||
expect_equal(db$contact_aon_previous, db$contact_aon_next) | ||
}) | ||
|
@@ -80,7 +81,7 @@ test_that('check_rt_reply catches both potential errors', { | |
} | ||
|
||
db <- create_dummy_database() | ||
db <- create_ticket_and_send_initial_correspondence(db) | ||
db <- create_ticket_and_send_initial_correspondence(db, database_path = "inst/test_db.csv") | ||
|
||
template <- read_initial_template(db$fund_program_name[1]) | ||
email_text <- sprintf(template, | ||
|