Blame view

scripts/run_ci_tests.sh 740 Bytes
7299bae6   tangwang   tests
1
  #!/bin/bash
99b72698   tangwang   测试回归钩子梳理
2
3
4
5
6
7
8
9
  # CI 门禁脚本:每次提交必跑的最小集合。
  #
  # 覆盖范围:
  #   1. tests/ci 下的服务契约测试(HTTP/JSON schema / 路由 / 鉴权)
  #   2. tests/ 下带 `contract` marker 的所有用例(冗余保障,防止 marker 与目录漂移)
  #   3. 搜索主路径 + ES 查询构建器的回归锚点(search 子系统)
  #
  # 超出这个范围的完整回归集请用 scripts/run_regression_tests.sh。
7299bae6   tangwang   tests
10
11
12
13
14
15
  
  set -euo pipefail
  
  cd "$(dirname "$0")/.."
  source ./activate.sh
  
99b72698   tangwang   测试回归钩子梳理
16
17
18
19
20
  echo "==> [CI-1/2] API contract tests (tests/ci + contract marker)..."
  python -m pytest tests/ci tests/ -q -m contract
  
  echo "==> [CI-2/2] Search core regression (search marker)..."
  python -m pytest tests/ -q -m "search and regression"