11
11
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
12
# See the License for the specific language governing permissions and
13
13
# limitations under the License.
14
-
15
14
import pytest
16
15
import pytest_asyncio
17
16
18
17
from toolbox_core .client import ToolboxClient
19
18
from toolbox_core .tool import ToolboxTool
20
19
20
+
21
21
# --- Shared Fixtures Defined at Module Level ---
22
22
@pytest_asyncio .fixture (scope = "function" )
23
23
async def toolbox ():
@@ -110,6 +110,7 @@ async def test_bind_params_callable(
110
110
assert "row3" in response
111
111
assert "row4" not in response
112
112
113
+
113
114
@pytest .mark .asyncio
114
115
@pytest .mark .usefixtures ("toolbox_server" )
115
116
class TestAuth :
@@ -123,7 +124,6 @@ async def test_run_tool_unauth_with_auth(
123
124
response = await tool (id = "2" )
124
125
assert "row2" in response
125
126
126
-
127
127
async def test_run_tool_no_auth (self , toolbox : ToolboxClient ):
128
128
"""Tests running a tool requiring auth without providing auth."""
129
129
tool = await toolbox .load_tool ("get-row-by-id-auth" )
@@ -151,7 +151,6 @@ async def test_run_tool_auth(self, toolbox: ToolboxClient, auth_token1: str):
151
151
response = await auth_tool (id = "2" )
152
152
assert "row2" in response
153
153
154
-
155
154
async def test_run_tool_param_auth_no_auth (self , toolbox : ToolboxClient ):
156
155
"""Tests running a tool with a param requiring auth, without auth."""
157
156
tool = await toolbox .load_tool ("get-row-by-email-auth" )
@@ -161,7 +160,6 @@ async def test_run_tool_param_auth_no_auth(self, toolbox: ToolboxClient):
161
160
):
162
161
await tool ()
163
162
164
-
165
163
async def test_run_tool_param_auth (self , toolbox : ToolboxClient , auth_token1 : str ):
166
164
"""Tests running a tool with a param requiring auth, with correct auth."""
167
165
tool = await toolbox .load_tool (
0 commit comments