import test from 'ava';
import fs from 'fs/promises';

/*
    Many CMSs replace '&' with &#038; in the embed code. Ensure that changes to build pipeline have not resulted in the '&&' operater being included in the built embed.js
*/
test("built embed.js script doesn't contain &&", async t => {
    const script = (await fs.readFile('dist/embed.js')).toString();
    t.is(script.includes('&&'), false);
});
