Summary
09_DeePKS_test1 is selected by CI through:
ctest --test-dir build -V --timeout 1700 -R 09_DeePKS
However, it currently passes without running any DeePKS unit-test cases.
This is different from 09_DeePKS, the DeePKS integration test, which does run real regression cases through tests/integrate/Autotest.sh.
What happens
tests/09_DeePKS/CMakeLists.txt registers:
add_test(
NAME 09_DeePKS_test1
COMMAND ${BASH} Autotest1.sh -a ${CMAKE_CURRENT_BINARY_DIR}/../../source/source_lcao/module_deepks/test/test_deepks
WORKING_DIRECTORY ${ABACUS_TEST_DIR}/09_DeePKS
)
But tests/09_DeePKS/Autotest1.sh reads a missing file:
testdir=`cat CASES1 | grep -E $case`
In CI this produces:
Since no cases are selected, the loop is skipped and the script exits successfully.
Additional concern
source/source_lcao/module_deepks/test/test_deepks is not registered like most module unit tests in ABACUS. It is built as a standalone executable and then indirectly included in CTest through tests/09_DeePKS/Autotest1.sh, instead of being registered directly with the project AddTest() / GTest-based unit-test flow.
Expected behavior
09_DeePKS_test1 should fail if its case list is missing or empty.
- DeePKS unit tests should actually run in CI.
- Ideally, DeePKS unit tests should be refactored to follow the same
AddTest() / GTest convention as other module unit tests.
Suggested fix
- Refactor
test_deepks into a normal module unit test registered directly through AddTest() / GTest.
Summary
09_DeePKS_test1is selected by CI through:However, it currently passes without running any DeePKS unit-test cases.
This is different from
09_DeePKS, the DeePKS integration test, which does run real regression cases throughtests/integrate/Autotest.sh.What happens
tests/09_DeePKS/CMakeLists.txtregisters:But
tests/09_DeePKS/Autotest1.shreads a missing file:testdir=`cat CASES1 | grep -E $case`In CI this produces:
Since no cases are selected, the loop is skipped and the script exits successfully.
Additional concern
source/source_lcao/module_deepks/test/test_deepksis not registered like most module unit tests in ABACUS. It is built as a standalone executable and then indirectly included in CTest throughtests/09_DeePKS/Autotest1.sh, instead of being registered directly with the projectAddTest()/ GTest-based unit-test flow.Expected behavior
09_DeePKS_test1should fail if its case list is missing or empty.AddTest()/ GTest convention as other module unit tests.Suggested fix
test_deepksinto a normal module unit test registered directly throughAddTest()/ GTest.