uce/site/tests/index.uce

35 lines
2.0 KiB
Plaintext

#include "testlib.h"
RENDER(Request& context)
{
bool local_only = test_demo_request_allowed(context);
site_tests_page_start(
"Coverage Index",
"Grouped runtime coverage pages for the published site. Public-safe pages stay available everywhere; stateful or infrastructure-touching pages stay local-only."
);
if(local_only)
{
?><div class="tests-note">Local-network access detected. The full suite, including filesystem, service, and task coverage pages, is available.</div><?
}
else
{
?><div class="tests-note">Public access detected. Local-only pages remain linked here but will return a restricted message instead of mutating server state.</div><?
}
?><div class="tests-grid"><?
site_tests_card("core.uce", "Core APIs", "Strings, UTF-8 handling, DTree, JSON, and small pure-function helpers.", "public");
site_tests_card("http.uce", "HTTP And Session", "Headers, cookies, query parsing, URI helpers, and session lifecycle checks.", "public");
site_tests_card("components.uce", "Components", "component_exists(), component_resolve(), component(), component_render(), and output buffering.", "public");
site_tests_card("markdown.uce", "Markdown", "markdown_to_ast(), markdown_to_html(), and component hook rendering.", "public");
site_tests_card("units.uce", "Units", "units_list(), unit_info(), unit_call(), unit_render(), and fixture loading.", "public");
site_tests_card("websockets.ws.uce", "WebSockets", "Browser-driven handshake and echo checks for ws_* helpers.", "public");
site_tests_card("io.uce", "Filesystem", "path_join(), file_put_contents(), file_append(), and file_get_contents().", "local-only");
site_tests_card("services.uce", "Sockets And Services", "socket_*, memcache_*, and MySQL reachability probes with skip-aware output.", "local-only");
site_tests_card("tasks.uce", "Tasks", "task(), task_pid(), task_repeat(), and task_kill() health checks.", "local-only");
?></div><?
?><div class="tests-section"><a class="button" href="../demo/index.uce">Back To Demo Pages</a></div><?
site_tests_page_end();
}