tests/testthat/_snaps/client.md

mcp_tools() errors informatively when file doesn't exist

Code
  mcp_tools("nonexistent/file/")
Condition
  Error in `mcp_tools()`:
  ! The mcptools MCP client configuration file does not exist.
  i Supply a non-NULL file `config` or create a file at the default configuration location '~/.config/mcptools/config.json'.

mcp_tools() errors informatively with invalid JSON

Code
  mcp_tools(tmp_file)
Condition
  Error in `mcp_tools()`:
  ! Configuration processing failed
  i The configuration file `config` must be valid JSON.
  Caused by error:
  ! lexical error: invalid char in json text.
                                         invalid json
                       (right here) ------^

mcp_tools() errors informatively without mcpServers entry

Code
  mcp_tools(tmp_file)
Condition
  Error in `mcp_tools()`:
  ! Configuration processing failed.
  i `config` must have a top-level mcpServers entry.


Try the mcptools package in your browser

Any scripts or data that you put into this service are public.

mcptools documentation built on Sept. 9, 2025, 5:45 p.m.