From 665bde6ccd209c88262b63d9224f9d5b95b2857d Mon Sep 17 00:00:00 2001 From: Anton Khorev Date: Tue, 8 Aug 2023 03:41:04 +0300 Subject: [PATCH] Use max changeset query limit setting in tests --- test/controllers/api/changesets_controller_test.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/test/controllers/api/changesets_controller_test.rb b/test/controllers/api/changesets_controller_test.rb index 40b8bc9f2..7f2cd0abb 100644 --- a/test/controllers/api/changesets_controller_test.rb +++ b/test/controllers/api/changesets_controller_test.rb @@ -1959,7 +1959,11 @@ module Api get changesets_path(:limit => "0") assert_response :bad_request - get changesets_path(:limit => "101") + get changesets_path(:limit => Settings.max_changeset_query_limit) + assert_response :success + assert_changesets [changeset5, changeset4, changeset3, changeset2, changeset1] + + get changesets_path(:limit => Settings.max_changeset_query_limit + 1) assert_response :bad_request end -- 2.39.5