chroma-core/chroma

[CLN] Break up test_api

オープン

#2,586 opened on 2024/07/28

 (4 件のコメント) (0 件のリアクション) (1 人の担当者)Rust (2,247 件のフォーク)batch import
by-chromacleanupgood first issue

Repository metrics

Stars
 (27,958 個のスター)
PR merge metrics
 (平均マージ 1d 16h) (30d で 80 merged PRs)

説明

test_api.py is a legacy of Chroma's launch, and provided some basic initial test coverage. We've continued to add to it as the project has evolved, and it's become a catch-all kitchen sink test file.

In practice a lot of the surface covered in test_api is better covered by our property tests. test_api.py should be broken up into separate files by API / object, and each object test should cover exceptional cases, rather than normal operation.

For example, we should save entropy in the property tests by not having them generate lists of IDs that are shorter than the lists of documents on a Collection.add call, but we should also be testing this path.

コントリビューターガイド