Skip to content

Commit

Permalink
test: 跳过test_tiktok_crawler测试
Browse files Browse the repository at this point in the history
  • Loading branch information
Johnserf-Seed committed Dec 10, 2024
1 parent 5e6ef03 commit f022c1c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion f2/apps/tiktok/test/test_tiktok_crawler.py
Original file line number Diff line number Diff line change
@@ -1,16 +1,21 @@
import os
import pytest
from f2.apps.tiktok.model import UserPost
from f2.apps.tiktok.filter import UserPostFilter
from f2.apps.tiktok.crawler import TiktokCrawler
from f2.utils.conf_manager import TestConfigManager

# 检查环境变量是否设置为跳过测试
skip_in_ci = os.getenv("SKIP_IN_CI", "false").lower() == "true"


@pytest.fixture
def cookie_fixture():
return TestConfigManager.get_test_config("tiktok")


@pytest.mark.asyncio
# @pytest.mark.asyncio
@pytest.mark.skipif(skip_in_ci, reason="Skipping test in CI environment")
async def test_crawler_by_secUid(cookie_fixture):
async with TiktokCrawler(cookie_fixture) as crawler:
params = UserPost(
Expand Down

0 comments on commit f022c1c

Please sign in to comment.