Skip to content

Commit 4d210d0

Browse files
committed
Fix prompts test to catch NotFoundError instead of std::out_of_range
PromptManager::get() now throws NotFoundError, update the test to match.
1 parent e9ce9aa commit 4d210d0

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

tests/prompts/basic.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
#include "fastmcpp/client/types.hpp"
2+
#include "fastmcpp/exceptions.hpp"
23
#include "fastmcpp/prompts/manager.hpp"
34
#include "fastmcpp/prompts/prompt.hpp"
45

@@ -216,7 +217,7 @@ void test_manager_get_nonexistent()
216217
{
217218
pm.get("nonexistent");
218219
}
219-
catch (const std::out_of_range&)
220+
catch (const NotFoundError&)
220221
{
221222
threw = true;
222223
}

0 commit comments

Comments
 (0)