Skip to content

Commit

Permalink
comparable->normalize
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelChirico committed Dec 17, 2023
1 parent 85ed38a commit 247a430
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .dev/roxygen_test.R
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@ if (length(new_not_old) > 0L) {

# Rd2txt() prints to its out= argument, so we'd have to compare file contents;
# plain parse_Rd() keeps srcref info that encodes the file path, which as.character() strips.
comparable_rd <- function(rd_file) as.character(parse_Rd(rd_file))
normalize_rd <- function(rd_file) as.character(parse_Rd(rd_file))

rd_equal <- function(f1, f2) isTRUE(all.equal(comparable_rd(f1), comparable_rd(f2)))
rd_equal <- function(f1, f2) isTRUE(all.equal(normalize_rd(f1), normalize_rd(f2)))

for (file in new_files) {
if (rd_equal(file.path(old_dir, file), file.path(new_dir, file))) {
Expand Down

0 comments on commit 247a430

Please sign in to comment.