Skip to contents

Remove a request stub

Usage

remove_request_stub(stub)

Arguments

stub

a request stub, of class StubbedRequest

Value

logical, TRUE if removed, FALSE if not removed

See also

Examples

(x <- stub_request("get", "https://httpbin.org/get"))
#> <webmockr stub> 
#>   method: get
#>   uri: https://httpbin.org/get
#>   with: 
#>     query: 
#>     body: 
#>     request_headers: 
#>   to_return: 
stub_registry()
#> <webmockr stub registry> 
#>  Registered Stubs
#>    GET: https://httpbin.org/get 
remove_request_stub(x)
stub_registry()
#> <webmockr stub registry> 
#>  Registered Stubs