test: Use -t=auto to generate some screenshots, detect -t=auto failure more reliably, exercise setting the initial profile, and fix various bugs that fell out.
Some checks are pending
Build Tilde Friends / Build-All (push) Waiting to run

This commit is contained in:
2024-11-25 09:35:55 -05:00
parent 6e83c08535
commit eb12ba6ed2
7 changed files with 65 additions and 14 deletions

View File

@ -10,6 +10,7 @@
#include "util.js.h"
#include <assert.h>
#include <inttypes.h>
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
@ -920,8 +921,8 @@ static void _test_pattern(const tf_test_options_t* options)
static void _test_auto_process_exit(uv_process_t* process, int64_t status, int termination_signal)
{
tf_printf("Process exit %d signal=%d.\n", (int)WEXITSTATUS(status), termination_signal);
assert(WEXITSTATUS(status) == 0);
tf_printf("Process exit %" PRId64 " signal=%d.\n", status, termination_signal);
assert(status == 0);
process->data = NULL;
uv_close((uv_handle_t*)process, NULL);
}
@ -958,6 +959,7 @@ static void _test_auto(const tf_test_options_t* options)
int spawn_result = uv_spawn(&loop, &process, &process_options);
if (spawn_result)
{
tf_printf("uv_spawn: %s\n", uv_strerror(spawn_result));
abort();
}
@ -970,6 +972,7 @@ static void _test_auto(const tf_test_options_t* options)
spawn_result = uv_spawn(&loop, &selenium, &process_options);
if (spawn_result)
{
tf_printf("uv_spawn: %s\n", uv_strerror(spawn_result));
abort();
}