From 801cf67a09708ae7cdca6fadfe19af8f806cc7a2 Mon Sep 17 00:00:00 2001 From: Tony Cook Date: Wed, 22 Oct 2025 09:26:22 +1100 Subject: [PATCH] t/test_pl.pod: document the new setup_multiple_progs() PREAMBLE --- t/test_pl.pod | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/t/test_pl.pod b/t/test_pl.pod index 1ee5e01dbff5..e5d4934d203a 100644 --- a/t/test_pl.pod +++ b/t/test_pl.pod @@ -318,7 +318,7 @@ Scan the given files for tests to be run by run_multiple_progs(). This is currently only used by F which itself is used by most tests that use run_multiple_progs() on other files. -Test files parsed by setup_multiple_progs() ignore any lines until a +Test files parsed by setup_multiple_progs() ignore most lines until a C<__END__> line is found. So in general, just use F, see F and @@ -774,10 +774,18 @@ C OPTIONS fatal Time to die at - line 1. -Test files parsed by setup_multiple_progs() ignore any lines until a +Test files parsed by setup_multiple_progs() ignore most lines until a C<__END__> line is found. This includes any test file based on F. +The lines that aren't ignored here by setup_multiple_progs() have the +form: + + /^#\s+PREAMBLE\s+(.*)$/ + +where each matching line (excluding the C<# PREAMBLE>) is prepended to +the code for each test case. + Tests are separated by lines containing exactly eight C<#>. A test (both code and expected result) can contain text matching