smartssr/test/test.ts
2023-07-27 12:37:27 +02:00

26 lines
707 B
TypeScript

import { expect, tap } from '@push.rocks/tapbundle';
import * as smartssr from '../ts/index.js';
let testSSRInstance: smartssr.SmartSSR;
tap.test('should create a valid smartssr instance', async () => {
testSSRInstance = new smartssr.SmartSSR({
debug: true,
});
});
tap.test('should render central.eu', async (tools) => {
await testSSRInstance.renderPage('https://lossless.com');
});
tap.test('should render lossless.com', async () => {
await testSSRInstance.renderPage('https://lossless.com');
});
tap.test('should render https://lossless.gmbh', async () => {
const renderedPage = await testSSRInstance.renderPage('https://lossless.gmbh');
console.log(renderedPage);
});
tap.start();