From 6fd50506d2e50d2faf2478a2883a2ef1b4840a78 Mon Sep 17 00:00:00 2001 From: Douglas Rumbaugh Date: Wed, 17 May 2023 16:00:20 -0400 Subject: Started implementing shard interface (not finished yet) --- tests/wirs_tests.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'tests/wirs_tests.cpp') diff --git a/tests/wirs_tests.cpp b/tests/wirs_tests.cpp index 828362d..c7edec9 100644 --- a/tests/wirs_tests.cpp +++ b/tests/wirs_tests.cpp @@ -185,7 +185,8 @@ START_TEST(t_weighted_sampling) results.reserve(k); size_t cnt[3] = {0}; for (size_t i=0; i<1000; i++) { - auto state = shard->get_sample_shard_state(lower_key, upper_key); + WIRS::wirs_query_parms parms = {lower_key, upper_key}; + auto state = shard->get_query_state(&parms); shard->get_samples(state, results, lower_key, upper_key, k, g_rng); @@ -193,7 +194,7 @@ START_TEST(t_weighted_sampling) cnt[results[j].key - 1]++; } - WIRS::delete_state(state); + WIRS::delete_query_state(state); } ck_assert(roughly_equal(cnt[0] / 1000, (double) k/4.0, k, .05)); -- cgit v1.2.3