summaryrefslogtreecommitdiff
path: root/test/math/kthperm.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/math/kthperm.cpp')
-rw-r--r--test/math/kthperm.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/test/math/kthperm.cpp b/test/math/kthperm.cpp
index 1b3e803..ca95699 100644
--- a/test/math/kthperm.cpp
+++ b/test/math/kthperm.cpp
@@ -1,9 +1,9 @@
#include "../util.h"
#include <math/kthperm.cpp>
-void stress_test() {
+void stress_test(int LIM) {
ll queries = 0;
- for (ll i = 0; i < 10'000; i++) {
+ for (int i = 0; i < LIM; i++) {
int n = Random::integer<int>(1, 100);
vector<ll> expected(n);
iota(begin(expected), end(expected), 0);
@@ -31,7 +31,8 @@ void performance_test() {
}
int main() {
- stress_test();
- performance_test();
+ stress_test(1'000);
+ if (!sanitize) stress_test(10'000);
+ if (!sanitize) performance_test();
}