Add no-require emulation test

This commit is contained in:
Rodrigo Arias 2023-11-10 16:08:58 +01:00
parent fa436604b7
commit 25cf46036d
2 changed files with 26 additions and 0 deletions

View File

@ -19,3 +19,4 @@ test_emu(sort-cpus-by-rank.c MP)
test_emu(tracedir-subdir.c MP DRIVER "tracedir-subdir.driver.sh") test_emu(tracedir-subdir.c MP DRIVER "tracedir-subdir.driver.sh")
test_emu(empty-stream.c SHOULD_FAIL REGEX "model_ovni_finish: thread .* is not dead") test_emu(empty-stream.c SHOULD_FAIL REGEX "model_ovni_finish: thread .* is not dead")
test_emu(require.c SHOULD_FAIL REGEX "unsupported ovni model version (want 666.66.6, have .*)") test_emu(require.c SHOULD_FAIL REGEX "unsupported ovni model version (want 666.66.6, have .*)")
test_emu(no-require.c REGEX "loading trace in compatibility mode")

View File

@ -0,0 +1,25 @@
/* Copyright (c) 2023 Barcelona Supercomputing Center (BSC)
* SPDX-License-Identifier: GPL-3.0-or-later */
#include <ovni.h>
#include "instr.h"
/* Test missing a call to ovni_thread_require() function */
int
main(void)
{
ovni_version_check();
ovni_proc_init(1, "node.1", 123);
ovni_thread_init(123);
ovni_add_cpu(0, 0);
/* No ovni_thread_require() call */
instr_thread_execute(0, -1, 0);
instr_end();
return 0;
}