To cite package ‘doctest’ in publications use:

Hugh-Jones D (2026). doctest: Generate Tests from Examples Using 'roxygen' and 'testthat'. R package version 0.4.0, https://github.com/hughjonesd/doctest.

Corresponding BibTeX entry:

  @Manual{,
    title = {doctest: Generate Tests from Examples Using 'roxygen' and
      'testthat'},
    author = {David Hugh-Jones},
    year = {2026},
    note = {R package version 0.4.0},
    url = {https://github.com/hughjonesd/doctest},
  }