MCPcopy Create free account
hub / github.com/enowdev/enowX-Coder / test_search_files_invalid_regex

Function test_search_files_invalid_regex

src-tauri/src/tools/executor.rs:954–971  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

952
953 #[tokio::test]
954 async fn test_search_files_invalid_regex() {
955 let sandbox_path = with_sandbox("search_invalid_regex");
956
957 let executor = ToolExecutor::new(sandbox_path);
958
959 let call = ToolCall {
960 tool: ToolName::SearchFiles,
961 input: serde_json::json!({
962 "pattern": "[invalid regex",
963 "path": "."
964 }),
965 };
966 let result = executor.execute(call).await;
967 assert!(result.is_error);
968 assert!(result.output.contains("Invalid regex"));
969
970 cleanup("search_invalid_regex");
971 }
972
973 #[tokio::test]
974 async fn test_search_files_no_matches() {

Callers

nothing calls this directly

Calls 3

with_sandboxFunction · 0.85
cleanupFunction · 0.85
executeMethod · 0.80

Tested by

no test coverage detected