Skip to content

tests: run 13 vector tests on the native build through get_metadata() - #168

Merged
tae898 merged 1 commit into
mainfrom
test/shared-vector-tests
Nov 1, 2026
Merged

tae898 merged 1 commit into
mainfrom
test/shared-vector-tests

Conversation

@tae898

@tae898 tae898 commented Nov 1, 2026 •

Copy link
Copy Markdown
Collaborator

Closes #167

Thirteen vector tests were skipped on the native build (NATIVE_NA_JVM_TESTS) only because they read the index configuration from the Java index behind the wrapper. They now read it through VectorIndex.get_metadata() / get_quantization(), which return the same values on both builds, and their list entries are removed.

  • test_vector.py: PQ parameters, custom id property, and the two approximate-search tests (the TypeIndex check is now index_name against bucket_index_name, plus get_quantization() == "PRODUCT").
  • test_vector_params_verification.py: the four quantization types, store_vectors_in_graph, add_hierarchy, the per-index cache settings, and the two max_connections default tests (the engine default is read from an index SQL creates without maxConnections, instead of GlobalConfiguration through JPype).
  • Asserts: the try/except fallbacks that parsed toString() are gone; each setting has one direct assert, and store_vectors_in_graph and add_hierarchy gained a negative control (a default index reads back False).
  • Left on the list, reason in the comment: test_encoding_param (encoding is not in get_metadata() on either build), the tests about the JVM itself, and the two WAL tests (no public read of the WAL setting on either build).

Verification: both whole files against the 26.11.1.dev0 dev wheels, on the old pair and on a pair built from main dd45b53947: JVM 60 passed; native passes all 13 rewritten tests. One unrelated native failure shows on those local dev wheels only, test_lsm_vector_search_with_filter (str(record.get_identity()) of an @rid that the engine e353330c5c sends as an RID object, wrapped twice); native CI builds against a newer engine and passes it, and the one-line fix is #170.

🤖 Generated with Claude Code

…A-JVM tests run on both builds

The pq, id_property, quantization, store_vectors_in_graph, add_hierarchy and cache tests, the two
TypeIndex checks of the approximate searches and the two max_connections default tests read a Java
index through _java_index or the JPype classes. get_metadata() returns the same values on the
native build, and an index SQL creates without maxConnections shows the engine default on both.
Their NATIVE_NA_JVM_TESTS entries go. test_encoding_param stays (encoding is not in
get_metadata()); the WAL tests stay (no public read of the WAL setting on either build).

Against the 26.11.1.dev0 dev wheels (old pair and the new dd45b53 pair) all 13 rewritten tests pass on native and JVM.

Closes #167

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@tae898
tae898 merged commit 736f9e8 into main Nov 1, 2026
36 checks passed
@tae898
tae898 deleted the test/shared-vector-tests branch November 1, 2026 12:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

tests: 13 vector tests skipped on native only because they read a Java object

1 participant