Description
The two main functionalities of this package are creating mock objects (functions) and selectively intercepting calls to a given function that originate in some other function. It can be used with any testing framework available for R. Mock objects can be injected with either this package's own stub() function or a similar with_mocked_binding() facility present in the 'testthat' package.
Downloads
62.1K
Last 30 days
444th
168.6K
Last 90 days
1.3M
Last year
Trend: +9% (30d vs prior 30d)
950
Last 30 days
2.8K
Last 90 days
6.9K
Last year
Trend: -28.1% (30d vs prior 30d)
11
Last 7 days
99
Last 30 days
5
All-time
⚠ Shared name: this package is also shipped elsewhere on openSUSE, so this count is not exclusive to autoCRAN (it is an upper bound).
751
Last 30 days
1.7K
Last 90 days
5.5K
Last year
Trend: +48.7% (30d vs prior 30d)
CRAN Check Status
Show all 13 flavors
| Flavor | Status |
|---|---|
| r-devel-linux-x86_64-debian-clang | OK |
| r-devel-linux-x86_64-debian-gcc | OK |
| r-devel-linux-x86_64-fedora-clang | OK |
| r-devel-linux-x86_64-fedora-gcc | OK |
| r-devel-windows-x86_64 | OK |
| r-oldrel-macos-arm64 | OK |
| r-oldrel-macos-x86_64 | OK |
| r-oldrel-windows-x86_64 | OK |
| r-patched-linux-x86_64 | OK |
| r-release-linux-x86_64 | OK |
| r-release-macos-arm64 | OK |
| r-release-macos-x86_64 | OK |
| r-release-windows-x86_64 | OK |
Check History
OK 14 OK · 0 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE Mar 10, 2026
Code
Structure
Lines of code
1,510
Files
22
Compiled share
0%
Has compiled src
No
Language breakdown
API
Exported functions
7
Internal functions
8
Testing & CI
Has tests
Yes
Test-to-code ratio
1.13
testthat edition
–
CI present
No
CI type
[]
PR gated
No
Docs
Return-value doc rate
33.3%
\dontrun example ratio
0%
Roxygen coverage
100%
Has pkgdown
No
NEWS present
Yes
Health & Security signals
Informational signals; not verdicts.
on.exit coverage
0%
Unsafe pattern score
9
Dep constraint coverage
0%
Secret pattern count
0
Bundled 3rd-party code
2 items
Portability & License
Min R version
3.6
System requirements
–
C++ standard
–
License
MIT + file LICENSE
License flags
SPDX valid, OSI approved
History
Versions
9
First release
2016-10-25
Latest release
2025-09-04
Avg cadence
353 days
Cold removal rate
100%
Dep drift
1
LOC over versions
Per-file churn detail lives in the source pipeline: https://github.com/r-observatory/cran-code-metrics.