toxiproxy_server.Rd
Control a server for use with testing. This is designed to be
used only by other packages that wish to run tests against a
toxiproxy server. You will need to set
TOXIPROXYR_SERVER_BIN_PATH
to point at the directory
containing the toxiproxy binary.
toxiproxy_server_install(quiet = FALSE, version = "v2.1.3") toxiproxy_server(config = NULL, seed = NULL, if_disabled = testthat::skip)
quiet | Suppress progress bars on install |
---|---|
version | Version of toxiproxy to install |
config | Not yet handled |
seed | Not yet handled |
if_disabled | Callback function to run if the toxiproxy
server is not enabled. The default, designed to be used within
tests, is |
The function toxiproxy_server_install
will install a
server, but only if the user opts in by setting the
environment variable TOXIPROXYR_SERVER_INSTALL
to
"true"
, and by setting TOXIPROXYR_SERVER_BIN_PATH
to
the directory where the binary should be downloaded to. This will
download a ~10MB binary from
https://github.com/Shopify/toxiproxy/releases so use with
care. It is intended only for use in automated testing
environments.