pub async fn run(
driver: Driver,
loc: PersistLocation,
content: &str,
path: Option<&Path>,
) -> Result<()>Expand description
Run a script: parse content into stanzas, execute each command, and either
compare its output to the stanza’s expected block or — when REWRITE is set
and path is given — rewrite the file in place with the actual outputs.
Returns Err if any stanza’s output differs from its expected block, so a
scripted run exits non-zero on a mismatch (and CI fails). A command that fails
renders as error: <message>, so an expected failure is asserted by its
golden block rather than a special command.