This is an automated email from the ASF dual-hosted git repository.

placave pushed a commit to branch pr48-regression-test
in repository https://gitbox.apache.org/repos/asf/datasketches-go.git

commit bd6753e368c5c666bae13da2695da174259b0b35
Author: Pierre Lacave <[email protected]>
AuthorDate: Mon Oct 6 22:20:28 2025 +0200

    Add regression test for PR48 bug fix
---
 internal/quick_select_test.go | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/internal/quick_select_test.go b/internal/quick_select_test.go
index 34f796b..f90781e 100644
--- a/internal/quick_select_test.go
+++ b/internal/quick_select_test.go
@@ -32,6 +32,14 @@ func TestQuickSelect(t *testing.T) {
                pivot    int
                expected int
        }{
+               {
+                       name:     "regression test PR48: two elements first 
smaller",
+                       arr:      []int{50, 100},
+                       lo:       0,
+                       hi:       1,
+                       pivot:    1,
+                       expected: 100,
+               },
                {
                        name:     "find median in odd length array",
                        arr:      []int{3, 1, 4, 1, 5, 9, 2, 6},


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to