Skip to content
This repository was archived by the owner on Apr 29, 2026. It is now read-only.

Commit a9bbebb

Browse files
committed
Update parsing regex for fn_name and fn_name_sub, from ::test[s]* to (?=::test).*
1 parent 068d73c commit a9bbebb

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

source/parse_test_report.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,13 +80,13 @@ tests_tbl_v2 <- tests_tbl |>
8080
dplyr::mutate(
8181
# extract function name
8282
fn_name = name |>
83-
stringr::str_remove("::test[s]*") |>
83+
stringr::str_remove("(?=::test).*") |>
8484
stringr::str_remove(FN_TEST_CLASS_PATTERN) |>
8585
stringr::str_extract(FN_NAME_PATTERN) |>
8686
stringr::str_remove_all("[\\(\\)]"),
8787
# extract any additional components to the test file
8888
fn_name_sub = name |>
89-
stringr::str_remove("::test[s]*") |>
89+
stringr::str_remove("(?=::test).*") |>
9090
stringr::str_remove(FN_TEST_CLASS_PATTERN) |>
9191
stringr::str_remove(fn_name) |>
9292
stringr::str_extract("^[^:-]+") |>

0 commit comments

Comments
 (0)