Assert the page does (or does not) ship JavaScript. Astro sends plain HTML unless the page uses a client directive, <ClientRouter /> or a script, so a content page that ships none is as fast as static HTML. The step reads the HTML that the server sent, not the DOM after the scripts ran.
Examples
Then the page should not ship JavaScript
And the page should not ship JavaScript
But the page should ship JavaScript
Then page should not ship JavaScript
And the page should not ship any JavaScript
Pattern
Then(/^(?:the )?page should( not)* ship (?:any )?JavaScript$/, …)
Part of @webship-js/astro-steps (github.com/webship/astro-steps), a step pack for Webship-js 2.0.x.