diff options
author | 2022-08-04 15:45:37 +0000 | |
---|---|---|
committer | 2022-08-04 15:45:37 +0000 | |
commit | b913c8afb50cb42b9d550af44198800d197c8243 (patch) | |
tree | dbbb507d16721c74bc3f7b0a64e1d5adc05283ae | |
parent | 4d6475227458f02361b62ff9603e79594bf7ec11 (diff) | |
download | astro-b913c8afb50cb42b9d550af44198800d197c8243.tar.gz astro-b913c8afb50cb42b9d550af44198800d197c8243.tar.zst astro-b913c8afb50cb42b9d550af44198800d197c8243.zip |
[ci] format
-rw-r--r-- | packages/astro/test/css-order.test.js | 26 |
1 files changed, 15 insertions, 11 deletions
diff --git a/packages/astro/test/css-order.test.js b/packages/astro/test/css-order.test.js index 82370af2b..4477d4660 100644 --- a/packages/astro/test/css-order.test.js +++ b/packages/astro/test/css-order.test.js @@ -15,7 +15,7 @@ describe('CSS production ordering', () => { let $ = cheerio.load(html); let out = []; $('link[rel=stylesheet]').each((i, el) => { - out.push($(el).attr('href')) + out.push($(el).attr('href')); }); return out; } @@ -24,10 +24,12 @@ describe('CSS production ordering', () => { let fixture = await loadFixture({ ...commonConfig }); await fixture.build(); staticHTML = await fixture.readFile('/one/index.html'); - staticCSS = await Promise.all(getLinks(staticHTML).map(async (href) => { - const css = await fixture.readFile(href); - return { href, css }; - })); + staticCSS = await Promise.all( + getLinks(staticHTML).map(async (href) => { + const css = await fixture.readFile(href); + return { href, css }; + }) + ); }); before(async () => { @@ -42,15 +44,17 @@ describe('CSS production ordering', () => { const request = new Request('http://example.com/one'); const response = await app.render(request); serverHTML = await response.text(); - serverCSS = await Promise.all(getLinks(serverHTML).map(async (href) => { - const css = await fixture.readFile(`/client${href}`); - return { href, css }; - })); + serverCSS = await Promise.all( + getLinks(serverHTML).map(async (href) => { + const css = await fixture.readFile(`/client${href}`); + return { href, css }; + }) + ); }); it('is in the same order for output: server and static', async () => { - const staticContent = staticCSS.map(o => o.css); - const serverContent = serverCSS.map(o => o.css); + const staticContent = staticCSS.map((o) => o.css); + const serverContent = serverCSS.map((o) => o.css); expect(staticContent).to.deep.equal(serverContent); }); |