tsbundle/test/test.ts

26 lines
628 B
TypeScript
Raw Normal View History

2019-04-20 17:59:33 +00:00
import { expect, tap } from '@pushrocks/tapbundle';
2022-03-14 15:32:12 +00:00
import * as tsbundle from '../dist_ts/index.js';
2019-04-20 17:59:33 +00:00
2021-07-22 19:55:08 +00:00
import * as path from 'path';
2021-07-23 13:45:23 +00:00
tap.test('should bundle test', async () => {
const tsbundleInstance = new tsbundle.TsBundle();
2022-03-14 15:32:12 +00:00
await tsbundleInstance.buildTest(
process.cwd() + '/test',
'./ts_web/index.ts',
'./dist_manual/test.js',
'rollup'
);
});
2019-04-20 17:59:33 +00:00
2021-07-23 13:45:23 +00:00
tap.test('should bundle production', async () => {
2021-07-22 19:55:08 +00:00
const tsbundleInstance = new tsbundle.TsBundle();
2022-03-14 15:32:12 +00:00
await tsbundleInstance.buildProduction(
process.cwd(),
'./test/ts_web/index.ts',
'./test/dist_manual/production.js'
);
});
2021-07-22 19:55:08 +00:00
2019-04-20 17:59:33 +00:00
tap.start();