From 54afa3ac7a69c3bf473974b04915124cae4927a3 Mon Sep 17 00:00:00 2001 From: Jiaming Yuan Date: Fri, 23 Apr 2021 13:01:44 +0800 Subject: [PATCH] Relax shotgun test. (#6900) It's non-deterministic algorithm, the test is flaky. --- tests/python/test_linear.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/python/test_linear.py b/tests/python/test_linear.py index eaf0e86a1..618cd64c5 100644 --- a/tests/python/test_linear.py +++ b/tests/python/test_linear.py @@ -61,7 +61,7 @@ class TestLinear: # result. if len(result) > 2: sampled_result = [score for i, score in enumerate(result) - if i % 2 == 0] + if i % 4 == 0] sampled_result[-1] = result[-1] # make sure the last one is used else: sampled_result = result