From 52b1dfa45a30b7a152f081ab58a0a952c14934b5 Mon Sep 17 00:00:00 2001 From: Zhicheng Zhang Date: Wed, 24 Jul 2024 19:11:19 +0800 Subject: [PATCH] skip api test for all forked pr --- tests/test_callback.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/test_callback.py b/tests/test_callback.py index f35a4f42d..b573fc51a 100644 --- a/tests/test_callback.py +++ b/tests/test_callback.py @@ -1,3 +1,6 @@ +import os + +import pytest from modelscope_agent.agents.role_play import RolePlay from modelscope_agent.callbacks.run_state import RunStateCallback from modelscope_agent.memory import MemoryWithRag @@ -5,7 +8,10 @@ from .ut_utils import MockTool +IS_FORKED_PR = os.getenv('IS_FORKED_PR', 'false') == 'true' + +@pytest.mark.skipif(IS_FORKED_PR, reason='only run modelscope-agent main repo') def test_llm_run_state(mocker): llm_config = { 'model': 'qwen-max',