MCPcopy Create free account
hub / github.com/alibaba/zvec / test_default

Method test_default

python/tests/test_schema.py:87–94  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

85# ----------------------------
86class TestVectorSchema:
87 def test_default(self):
88 field = VectorSchema("vector", data_type=DataType.VECTOR_FP32, dimension=128)
89 assert field.name == "vector"
90 assert field.data_type == DataType.VECTOR_FP32
91 assert field.dimension == 128
92 assert field.index_param is not None
93 assert field.index_param.type == IndexType.FLAT
94 assert field.index_param.metric_type == MetricType.IP
95
96 def test_custom(self):
97 field = VectorSchema(

Callers

nothing calls this directly

Calls 1

VectorSchemaClass · 0.90

Tested by

no test coverage detected