From a213de7a50f5dc541772664410642d005e3ea56d Mon Sep 17 00:00:00 2001 From: Christian Stenger Date: Thu, 29 Jun 2023 14:08:30 +0200 Subject: [PATCH] AutoTest: Fix seed ranges Tweak the default range of 0..99 resulting from using a QSpinBox to some wider range. Change-Id: Id1a64e283bee96d31df8bbad2f6e8039675df817 Reviewed-by: Qt CI Bot Reviewed-by: David Schulz --- src/plugins/autotest/boost/boosttestsettings.cpp | 1 + src/plugins/autotest/gtest/gtestsettings.cpp | 1 + 2 files changed, 2 insertions(+) diff --git a/src/plugins/autotest/boost/boosttestsettings.cpp b/src/plugins/autotest/boost/boosttestsettings.cpp index 4cf92251738..4ff10a90ce8 100644 --- a/src/plugins/autotest/boost/boosttestsettings.cpp +++ b/src/plugins/autotest/boost/boosttestsettings.cpp @@ -60,6 +60,7 @@ BoostTestSettings::BoostTestSettings(Id settingsId) seed.setSettingsKey("Seed"); seed.setEnabled(false); + seed.setRange(0, INT_MAX); // UINT_MAX would be correct, but inner QSpinBox is limited to int seed.setLabelText(Tr::tr("Seed:")); seed.setToolTip(Tr::tr("A seed of 0 means no randomization. A value of 1 uses the current " "time, any other value is used as random seed generator.")); diff --git a/src/plugins/autotest/gtest/gtestsettings.cpp b/src/plugins/autotest/gtest/gtestsettings.cpp index 7fa1e534797..7aa370366f3 100644 --- a/src/plugins/autotest/gtest/gtestsettings.cpp +++ b/src/plugins/autotest/gtest/gtestsettings.cpp @@ -43,6 +43,7 @@ GTestSettings::GTestSettings(Id settingsId) seed.setSettingsKey("Seed"); seed.setSpecialValueText({}); + seed.setRange(0, 99999); seed.setEnabled(false); seed.setLabelText(Tr::tr("Seed:")); seed.setToolTip(Tr::tr("A seed of 0 generates a seed based on the current timestamp."));