MCPcopy Index your code
hub / github.com/PaddlePaddle/FastDeploy / test_normal_version

Method test_normal_version

tests/utils/test_version.py:30–32  ·  view source on GitHub ↗

测试正常版本号解析

(self, mock_file)

Source from the content-addressed store, hash-verified

28
29 @patch("builtins.open", new_callable=mock_open, read_data="fastdeploy version: 1.0.0\nother info")
30 def test_normal_version(self, mock_file):
31 """测试正常版本号解析"""
32 self.assertEqual(current_package_version(), "1.0.0")
33
34 @patch("builtins.open", side_effect=FileNotFoundError)
35 def test_file_not_found(self, mock_file):

Callers

nothing calls this directly

Calls 1

current_package_versionFunction · 0.90

Tested by

no test coverage detected