summaryrefslogtreecommitdiff
path: root/test/string/rollingHashCf.cpp
diff options
context:
space:
mode:
authorGloria Mundi <gloria@gloria-mundi.eu>2025-11-19 02:20:56 +0100
committerGloria Mundi <gloria@gloria-mundi.eu>2025-11-19 02:20:56 +0100
commit17232918b51d27500af905dc3d3d82cd43d6ddf5 (patch)
tree1c5d52f03eead415cc53317008032fe84238c187 /test/string/rollingHashCf.cpp
parentbf4eda36d4c13be468236bf33baa2574e8692ca7 (diff)
parentcdeded176c18240579168ee8461c5101abb47e78 (diff)
merge mzuenni
Diffstat (limited to 'test/string/rollingHashCf.cpp')
-rw-r--r--test/string/rollingHashCf.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/test/string/rollingHashCf.cpp b/test/string/rollingHashCf.cpp
index f7ce357..d0f90aa 100644
--- a/test/string/rollingHashCf.cpp
+++ b/test/string/rollingHashCf.cpp
@@ -39,13 +39,13 @@ void testTiny() {
cerr << "tiny: ok" << endl;
}
-void testSmall() {
+void testSmall(int depth) {
set<decltype(getHash(""))> got;
ll expected = 0;
auto dfs = [&](auto&& self, string pref)->void {
expected++;
got.insert(getHash(pref));
- if(ssize(pref) >= 5) return;
+ if(ssize(pref) >= depth) return;
for (char c = 'a'; c <= 'z'; c++) {
self(self, pref + c);
}
@@ -88,7 +88,7 @@ void performance_test() {
int main() {
testThueMorse();
testTiny();
- testSmall();
+ testSmall(sanitize ? 4 : 5);
stress_test();
- performance_test();
+ if (!sanitize) performance_test();
}