rhbz_1647130: Remove tmp_dir at the end

Guarantee the temporary directory is removed after the execution of this
test.
This commit is contained in:
Tulio Magno Quites Machado Filho 2024-11-13 16:30:58 -03:00
commit c140bdf103

View file

@ -5,3 +5,4 @@ tmp_dir=$(mktemp -d)
echo 'int main(int argc, char*argv[]) { while(argc--) new int(); return 0; }' > "$tmp_cpp"
scan-build -o "$tmp_dir" clang++ -c "$tmp_cpp" -o /dev/null
(scan-view --no-browser "$tmp_dir"/* & WPID=$! && sleep 10s && kill $WPID)
rm -rf "$tmp_cpp" "$tmp_dir"