From 62a51c0084511867665d87f0740632532abf3234 Mon Sep 17 00:00:00 2001 From: yusyus Date: Mon, 12 Jan 2026 22:56:37 +0300 Subject: [PATCH] fix: Correct mock patch path for install_skill tests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixed 4 failing tests in TestPackagingTools that were patching the wrong module path. The tests were patching: 'skill_seekers.mcp.tools.packaging_tools.fetch_config_tool' But fetch_config_tool is actually in source_tools, not packaging_tools. Changed all 4 tests to patch: 'skill_seekers.mcp.tools.source_tools.fetch_config_tool' Tests now passing: - test_install_skill_with_config_name ✅ - test_install_skill_with_config_path ✅ - test_install_skill_unlimited ✅ - test_install_skill_no_upload ✅ Result: 81/81 MCP tests passing (was 77/81) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 --- tests/test_mcp_fastmcp.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/test_mcp_fastmcp.py b/tests/test_mcp_fastmcp.py index b0e497d..a8d8ac1 100644 --- a/tests/test_mcp_fastmcp.py +++ b/tests/test_mcp_fastmcp.py @@ -534,7 +534,7 @@ class TestPackagingTools: async def test_install_skill_with_config_name(self): """Test complete install workflow with config name.""" # Mock the fetch_config_tool import that install_skill_tool uses - with patch('skill_seekers.mcp.tools.packaging_tools.fetch_config_tool') as mock_fetch: + with patch('skill_seekers.mcp.tools.source_tools.fetch_config_tool') as mock_fetch: mock_fetch.return_value = [Mock(text="Config fetched")] result = await server_fastmcp.install_skill( @@ -547,7 +547,7 @@ class TestPackagingTools: async def test_install_skill_with_config_path(self, sample_config): """Test complete install workflow with config path.""" - with patch('skill_seekers.mcp.tools.packaging_tools.fetch_config_tool') as mock_fetch: + with patch('skill_seekers.mcp.tools.source_tools.fetch_config_tool') as mock_fetch: mock_fetch.return_value = [Mock(text="Config ready")] result = await server_fastmcp.install_skill( @@ -560,7 +560,7 @@ class TestPackagingTools: async def test_install_skill_unlimited(self): """Test install workflow with unlimited pages.""" - with patch('skill_seekers.mcp.tools.packaging_tools.fetch_config_tool') as mock_fetch: + with patch('skill_seekers.mcp.tools.source_tools.fetch_config_tool') as mock_fetch: mock_fetch.return_value = [Mock(text="Config fetched")] result = await server_fastmcp.install_skill( @@ -573,7 +573,7 @@ class TestPackagingTools: async def test_install_skill_no_upload(self): """Test install workflow without auto-upload.""" - with patch('skill_seekers.mcp.tools.packaging_tools.fetch_config_tool') as mock_fetch: + with patch('skill_seekers.mcp.tools.source_tools.fetch_config_tool') as mock_fetch: mock_fetch.return_value = [Mock(text="Config fetched")] result = await server_fastmcp.install_skill(