Skip to content

Commit

Permalink
comparison() accepts messages of length > 1
Browse files Browse the repository at this point in the history
  • Loading branch information
Kirill Müller committed Apr 16, 2016
1 parent b80c637 commit 5700234
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions R/compare.R
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ compare <- function(x, y, ...) {

comparison <- function(equal = TRUE, message = "Equal") {
stopifnot(is.logical(equal), length(equal) == 1)
stopifnot(is.character(message), length(message) == 1)
stopifnot(is.character(message))

structure(
list(
equal = equal,
message = message
message = paste(message, collapse = "\n")
),
class = "comparison"
)
Expand Down

0 comments on commit 5700234

Please sign in to comment.