mockery

Mocking Library for R

CRAN Package

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_mock() facility present in the 'testthat' package.


Documentation


Team


Insights

Last 30 days

This package has been downloaded 73,198 times in the last 30 days. This work is reaching a lot of screens. A significant achievement indeed! The following heatmap shows the distribution of downloads per day. Yesterday, it was downloaded 852 times.

Sun
Mon
Tue
Wed
Thu
Fri
Sat
0 downloadsMar 16, 2025
0 downloadsMar 17, 2025
0 downloadsMar 18, 2025
0 downloadsMar 19, 2025
3,540 downloadsMar 20, 2025
3,393 downloadsMar 21, 2025
3,059 downloadsMar 22, 2025
3,218 downloadsMar 23, 2025
3,594 downloadsMar 24, 2025
3,505 downloadsMar 25, 2025
3,529 downloadsMar 26, 2025
3,348 downloadsMar 27, 2025
3,207 downloadsMar 28, 2025
2,794 downloadsMar 29, 2025
3,007 downloadsMar 30, 2025
3,460 downloadsMar 31, 2025
3,635 downloadsApr 1, 2025
3,373 downloadsApr 2, 2025
3,144 downloadsApr 3, 2025
2,884 downloadsApr 4, 2025
2,658 downloadsApr 5, 2025
2,740 downloadsApr 6, 2025
2,973 downloadsApr 7, 2025
920 downloadsApr 8, 2025
1,511 downloadsApr 9, 2025
1,076 downloadsApr 10, 2025
1,063 downloadsApr 11, 2025
981 downloadsApr 12, 2025
763 downloadsApr 13, 2025
1,272 downloadsApr 14, 2025
1,236 downloadsApr 15, 2025
1,212 downloadsApr 16, 2025
1,251 downloadsApr 17, 2025
852 downloadsApr 18, 2025
0 downloadsApr 19, 2025
763
3,635

The following line graph shows the downloads per day. You can hover over the graph to see the exact number of downloads per day.

Last 365 days

This package has been downloaded 905,856 times in the last 365 days. This is starting to look legendary. Enough downloads to inspire a dedicated panel discussion! The day with the most downloads was Feb 11, 2025 with 3,753 downloads.

The following line graph shows the downloads per day. You can hover over the graph to see the exact number of downloads per day.

Data provided by CRAN


Binaries


Dependencies

  • Imports1 package
  • Suggests3 packages
  • Reverse Imports2 packages
  • Reverse Suggests127 packages