/* Shared reporter for the ES module section of jscheck.html.
 *
 * Imported by both the external entry point and the inline modules in the
 * page, which is the check that the two graphs are one: a second instance
 * would keep its own `results` and the counts would not add up.
 *
 * Nothing is written into the page from here. A module is deferred, so these
 * run after the page's own script has finished; the results are parked on
 * window and the load handler in jscheck.html reports them through the same
 * harness as everything else.
 */

const results = [];

export function report(name, ok, detail) {
	results.push({ name: name, ok: !!ok, detail: detail || "" });
	window.jscheckModuleResults = results;
}
