Skip to content

Commit

Permalink
UPLOAD v0.1.6
Browse files Browse the repository at this point in the history
  • Loading branch information
davidycliao committed Oct 31, 2023
1 parent de44b3e commit eb7721e
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 8 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
.Rhistory
.RData
.Ruserdata
.Rmd
docs
inst/doc
/doc/
Expand Down
6 changes: 3 additions & 3 deletions R/meeting.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#' The Spoken Meeting Records 委員發言
#'@title The Spoken Meeting Records 委員發言
#'
#'@author David Liao (davidycliao@@gmail.com)
#'
Expand Down Expand Up @@ -105,7 +105,7 @@ get_meetings <- function(start_date = NULL, end_date = NULL, meeting_unit = NULL
}


#' The Meeting Records of Cross-caucus Session 黨團協商資訊
#'@title The Meeting Records of Cross-caucus Session 黨團協商資訊
#'
#'@author David Liao (davidycliao@@gmail.com)
#'
Expand Down Expand Up @@ -214,7 +214,7 @@ get_caucus_meetings <- function(start_date = NULL, end_date = NULL,
}


#' The Video Information of Meetings and Committees 院會及委員會之委員發言片段相關影片資訊
#'@title The Video Information of Meetings and Committees 院會及委員會之委員發言片段相關影片資訊
#'
#'@param start_date character Must be formatted in Minguo (ROC) calendar with three
#'forward slashes between year, month and day, e.g. "106/10/20".
Expand Down
15 changes: 10 additions & 5 deletions tests/testthat/test_meeting.R
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,15 @@ test_that("get_caucus_meetings", {
expect_equal(get_caucus_meetings(start_date = "106/10/20", end_date = "107/03/10", verbose = FALSE)$retrieved_number ,30)
})

test_that("get_speech_video", {
expect_equal(get_speech_video(start_date = "105/10/20", end_date = "109/03/10")$retrieved_number, 547)
expect_equal(get_speech_video(start_date = "105/10/20", end_date = "109/03/10", verbose = FALSE)$retrieved_number, 547)
expect_error(get_speech_video(start_date = "104/01/01", end_date = "104/01/02", verbose = FALSE), "The query is unavailable.")
# test_that("get_speech_video", {
# expect_equal(get_speech_video(start_date = "105/10/20", end_date = "109/03/10")$retrieved_number, 547)
# expect_equal(get_speech_video(start_date = "105/10/20", end_date = "109/03/10", verbose = FALSE)$retrieved_number, 547)
# expect_error(get_speech_video(start_date = "104/01/01", end_date = "104/01/02", verbose = FALSE), "The query is unavailable.")
#
# })



})

test_that("get_public_debates", {
expect_equal(get_public_debates(term = 10, session_period = 1)$retrieved_number, 107)
Expand All @@ -29,6 +32,8 @@ test_that("get_public_debates", {

})

get_speech_video


# test_that("get_committee_record", {
# expect_equal(get_committee_record(term = 8, session_period= 1, verbose = FALSE)$retrieved_number, 613)
Expand Down

0 comments on commit eb7721e

Please sign in to comment.