Commit 25cf61bd authored by Leif Walsh's avatar Leif Walsh Committed by Yoni Fogel

add upgrade stress tests to the nightly suite

refs #4797


git-svn-id: file:///svn/toku/tokudb@45019 c7de825b-a66e-492c-adef-691d508d4ae1
parent fd7fd2aa
......@@ -93,6 +93,23 @@ foreach(test ${stress_tests})
endif()
endforeach(test)
## upgrade stress tests are 5 minutes long, don't need to run them always
if(NOT @RUN_LONG_TESTS@)
foreach(test ${stress_tests})
if (NOT ${test} MATCHES test_stress_openclose)
foreach(oldver 4.2.0 5.0.8 5.2.7)
foreach(p_or_s pristine stressed)
if (NOT (${test} MATCHES test_stress4 AND ${p_or_s} MATCHES stressed))
foreach(size 2000 200000 50000000)
list(APPEND CTEST_CUSTOM_TESTS_IGNORE ydb/${test}/upgrade/${oldver}/${p_or_s})
endforeach(size)
endif ()
endforeach(p_or_s)
endforeach(ver)
endif ()
endforeach(test)
endif()
set(tdb_tests_that_should_fail "ydb/${stress_tests}")
string(REGEX REPLACE ";" ";ydb/" stress_tests "${stress_tests}")
......
......@@ -451,6 +451,25 @@ if(BUILD_TESTING)
endif()
endforeach(src)
configure_file(run_upgrade_stress_test.sh . COPYONLY)
foreach(src ${stress_test_srcs})
if (NOT ${src} MATCHES test_stress_openclose)
string(REGEX REPLACE "\\.c$" ".tdb" test "${src}")
foreach(oldver 4.2.0 5.0.8 5.2.7)
foreach(p_or_s pristine stressed)
if (NOT (${src} MATCHES test_stress4 AND ${p_or_s} MATCHES stressed))
foreach(size 2000 200000 50000000)
add_custom_executable(upgrade_${oldver}_${p_or_s}_${size} ${test} ${src})
add_test(ydb/${test}/upgrade/${oldver}/${p_or_s}
${CMAKE_CFG_INTDIR}/run_upgrade_stress_test.sh $<TARGET_FILE:upgrade_${oldver}_${p_or_s}_${size}_${test}> ${TOKU_SVNROOT}/tokudb.data/old-stress-test-envs/${oldver}/saved${p_or_s}-${size}-dir dir.upgrade_${oldver}_${p_or_s}_${size}_${src}.c.tdb ${size} 600)
endforeach(size)
endif ()
endforeach(p_or_s)
endforeach(ver)
endif ()
endforeach(src)
## for some reason this rule doesn't run with the makefile and it crashes with this rule, so I'm disabling this special case
#declare_custom_tests(test_thread_stack.tdb)
#add_custom_command(OUTPUT run_test_thread_stack.sh
......
#!/bin/bash
if [[ $# -lt 5 ]]; then exit 1; fi
bin=$1; shift
saveddir=$1; shift
envdir=$1; shift
size=$1; shift
time=$1; shift
rm -rf $envdir
cp -r $saveddir $envdir
$bin --only_stress --num_elements $size --num_seconds $time
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment