From 6380ba7514c79e26c778a57d5bf8db4ce39981a0 Mon Sep 17 00:00:00 2001 From: iomgaa Date: Wed, 22 Jul 2026 11:28:20 -0400 Subject: [PATCH] fix: sync __version__ with pyproject and pin test to single source --- src/polygateway/__init__.py | 2 +- tests/unit/test_package.py | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/polygateway/__init__.py b/src/polygateway/__init__.py index 42dc04d..a71aa37 100644 --- a/src/polygateway/__init__.py +++ b/src/polygateway/__init__.py @@ -31,7 +31,7 @@ from polygateway.types import ( SourceConfig, ) -__version__ = "0.1.0" +__version__ = "1.0.0" __all__ = [ "DEFAULT_PROFILES", diff --git a/tests/unit/test_package.py b/tests/unit/test_package.py index 9959277..2335bdc 100644 --- a/tests/unit/test_package.py +++ b/tests/unit/test_package.py @@ -1,10 +1,15 @@ """包基线冒烟测试:可导入、版本号存在。""" +from pathlib import Path + import polygateway def test_package_importable_with_version() -> None: - assert polygateway.__version__ == "0.1.0" + import tomllib + + declared = tomllib.loads(Path("pyproject.toml").read_text())["project"]["version"] + assert polygateway.__version__ == declared # 单一版本源: 与 pyproject 同步 def test_ocr_public_surface_exported():