Skip to content

Commit

Permalink
Sync with fledge
Browse files Browse the repository at this point in the history
  • Loading branch information
krlmlr committed Feb 17, 2022
1 parent 6b47da0 commit 7ed417b
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/R-CMD-check-dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Can't be run as part of commits
on:
schedule:
- cron: '5 0 * * *' # only run on main branch
- cron: '5 0 * * *' # 05:00 UTC every day only run on main branch
push:
branches:
- "cran-*"
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/check/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,10 @@ runs:
- name: Show test output
if: always()
run: |
## -- Show test output --
echo "::group::Test output"
find check -name '*.Rout*' -exec head -n 1000000 '{}' \; || true
echo "::endgroup::"
shell: bash

- name: Upload check results
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/update-snapshots/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,15 @@ runs:
tryCatch(
{
result <- as.data.frame(testthat::test_local(pattern = pattern, reporter = "silent", stop_on_failure = FALSE))
failures <- result[result$failed > 0, ]
failures <- result[result$failed + result$warning > 0, ]
if (nrow(failures) > 0) {
writeLines("Tests failed")
writeLines("Snapshot tests failed/warned.")
print(failures[names(failures) != "result"])
print(failures$result)
testthat::snapshot_accept()
writeLines("::set-output name=changed::true")
} else {
writeLines("Snapshot tests ran successfully.")
}
},
error = print
Expand Down

0 comments on commit 7ed417b

Please sign in to comment.