0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2025-01-20 22:12:38 -05:00
astro/test/astro-basic.test.js

20 lines
458 B
JavaScript
Raw Normal View History

import { suite } from 'uvu';
import * as assert from 'uvu/assert';
import { doc } from './test-utils.js';
import { setup } from './helpers.js';
2021-04-13 18:08:32 -06:00
const Basics = suite('Basic test');
setup(Basics, './fixtures/astro-basic');
Basics('Can load page', async ({ runtime }) => {
const result = await runtime.load('/');
assert.equal(result.statusCode, 200);
const $ = doc(result.contents);
assert.equal($('h1').text(), 'Hello world!');
});
2021-04-05 18:18:39 +00:00
Basics.run();