Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: R Tests

on:
push:
pull_request:

jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true
- name: Install dependencies
run: |
install.packages(c(
"testthat", "tidyverse", "rstatix", "ggstatsplot", "ggsignif",
"see", "ggpmisc", "writexl", "readxl", "emoa", "effectsize"
))
Comment on lines +15 to +20

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Run dependency install step inside R

The workflow step that is supposed to install the R packages (lines 15‑20) runs install.packages(...) as a plain shell command. GitHub Actions steps default to bash, so the runner throws install.packages: command not found before any dependencies are installed or tests run. Wrap the installation in an R invocation (e.g. Rscript -e 'install.packages(...)' or shell: Rscript {0}) so the command executes inside R and the job can proceed.

Useful? React with 👍 / 👎.

Comment on lines +17 to +20

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Workflow omits easystats required during tests

In the helper (tests/testthat/helper-r_code.R:2) the tests disable automatic installation, yet r_functionality.R still executes library(easystats) (line 57). The workflow’s dependency list (lines 17‑20) never installs easystats, so sourcing the file immediately errors with “there is no package called ‘easystats’” and the suite never runs. Ensure that easystats (and any other packages loaded unconditionally) are installed in this step before sourcing the script, or stop disabling auto installs for the workflow.

Useful? React with 👍 / 👎.

- name: Run tests
run: |
Rscript -e 'testthat::test_dir("tests/testthat", reporter = "summary")'
Loading
Loading