Skip to content

httptest

4.2.3

A Test Environment for HTTP Requests

55packages depend
52.9Kdownloads / year
98.0%test coverage
8/13checks pass

Overview

About
Maintained by Neal RichardsonFirst published 2016-12-3120 releasesCRAN page ↗GitHub ↗

Testing and documenting code that communicates with remote servers can be painful. Dealing with authentication, server state, and other complications can make testing seem too costly to bother with. But it doesn't need to be that hard. This package enables one to test all of the logic on the R sides of the API in your package without requiring access to the remote service. Importantly, it provides three contexts that mock the network connection in different ways, as well as testing functions to assert that HTTP requests were---or were not---made. It also allows one to safely record real API responses to use as test fixtures. The ability to save responses and load them offline also enables one to write vignettes and other dynamic documents that can be distributed without access to a live server.

Install

Health

CRAN checks
5NOTE8OK
Failing flavors
  • NOTE r-devel-linux-x86_64-debian-clang
  • NOTE r-devel-linux-x86_64-debian-gcc
  • NOTE r-devel-linux-x86_64-fedora-clang
  • NOTE r-devel-linux-x86_64-fedora-gcc
  • NOTE r-devel-windows-x86_64
Slowest check: 1.9 min · r-oldrel-windows-x86_64
Code health
Yes
Tests · ratio 1.44
98.0%
Coverage · measured lines
100%
Documentation · exports
7
Dependencies · direct
Check history
  • NOTE2026-07-16
    11 OK · 2 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE
  • OK2026-06-09
    13 OK · 0 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE
  • ERROR2026-06-08
    12 OK · 0 NOTE · 0 WARNING · 1 ERROR · 0 FAILURE
  • OK2026-03-10
    14 OK · 0 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE

Documentation

Documentation
READMEYes · 1,113 wordsVignettesYes · dynamicpkgdown siteNoNEWSYes · 100% structuredCode of conductNoContributing guideNo
Examples that run
83%
Documented parameters
98%
Return-value docs
96%
References docs
0%

Downloads

52.9K
CRAN downloads in the past year
Rank #1,821 · ~145/day · ~4.4K/mo
Daily download trend is not available in this view yet.
3.8K30 days
12.9K90 days
52.9K1 year
Compare downloads with other packages →
Also on216 r2u15 autocran58 c2d4u

Repository

Repository
83Stars
14Forks
15Open issues
0Open PRs
6Releases
257Commits
14Contributors
httptest-frameworkmockrstats
257 commits · Last activity 2026-07-31 · 0% stars, 30d

Stars over time

2024-12-10 · 812026-07-07 · 83

Repository practices

Upstream repositoryBeta

3 development-tooling and community-health practices detected across 3 families in the upstream repository

Checks run against github.com/nealrichardson/httptest on 2026-08-09.

Continuous integration (1)
GitHub Actions
Reproducibility and dev environment (1)
Makefile
Automation and maintenance (1)
Dependabot
How this is detected·Detection ruleset v1 (2026-07-18)

Dependencies

Declared dependencies
10 external dependencies (excludes base and recommended)
Depends (2)
R >= 3.5.0testthat
Imports (6)
LinkingTo (0)
none
Enhances (0)
none

Code & Tests

People & History

People (3)
Maintainer (1)
Author, Maintainer
Authors (1)
Author, Maintainer
Contributors (2)
Contributor · added in 4.0.0
Contributor · added in 4.0.0
Package Timeline

20 releases. Pick two to compare their code metrics. R releases are shown for context.

  • R
    R 4.6.0 released · 2026-04-24
  • 4.2.3Latest
    2025-11-15 · current release · diff ↗
  • R
    R 4.5.0 released · 2025-04-11
  • R
    R 4.4.0 released · 2024-04-24
  • 4.2.2
    2024-01-23 · diff ↗
  • 4.2.1
    2023-06-12 · diff ↗
  • 4.2.0
    2023-05-29 · diff ↗
  • R
    R 4.3.0 released · 2023-04-21
  • R
    R 4.2.0 released · 2022-04-22
  • 4.1.0
    2021-09-22 · diff ↗
  • R
    R 4.1.0 released · 2021-05-18
  • 4.0.0
    2021-02-01 · diff ↗
  • R
    R 4.0.0 released · 2020-04-24
  • 3.3.0
    2020-01-28 · diff ↗
  • R
    R 3.6.0 released · 2019-04-26
  • 3.2.2
    2018-12-07 · diff ↗
Show 15 earlier events
  • 3.2.0
    2018-11-09 · diff ↗
  • 3.1.0
    2018-06-19 · diff ↗
  • R
    R 3.5.0 released · 2018-04-23
  • 3.0.0
    2018-01-16 · diff ↗
  • 2.3.4
    2017-11-14 · diff ↗
  • 2.3.2
    2017-10-20 · diff ↗
  • 2.1.2
    2017-08-05 · diff ↗
  • 2.1.0
    2017-07-31 · diff ↗
  • 2.0.0
    2017-06-05 · diff ↗
  • R
    R 3.4.0 released · 2017-04-21
  • 1.3.0
    2017-04-13 · diff ↗
  • 1.2.0
    2017-03-22 · diff ↗
  • 1.1.0
    2017-02-03 · diff ↗
  • 1.0.0
    2016-12-31
  • R
    R 3.3.0 released · 2016-05-03

Package metadata

First published
2016-12-31
Total releases
20 / 10 yrs
License
MIT + file LICENSE OSI
Minimum R
≥ 3.5.0
Download size
118 KB
Installed size
not tracked yet
With dependencies
not tracked yet
Appears in task views

Cite

Cite this package

Run in R for the authors' preferred citation:

citation("httptest")
Richardson, N., Keane, J., & Salmon, M. (2025). httptest: A Test Environment for HTTP Requests (Version 4.2.3) [Computer software]. https://doi.org/10.32614/CRAN.package.httptest

This is what citation() produces when a package has no citation file of its own. If it prints something else, use that.

Cite the R Observatory

For a number measured here: a download total, a coverage figure, an archival date.

APA

Balamuta, J. J. (2026). R Observatory: Metrics for httptest version 4.2.3 [Data set]. HJJB, LLC. Data release v2026-08-15. https://doi.org/10.5281/zenodo.21843040

From data release v2026-08-15, which the citation names so these numbers can be found later. More on citing and the projects behind them.

Report a problem with this page →

Privacy choices

These apply to this browser and are stored on this device only. Nothing about your choice is sent to us.

Read the privacy policy