mirror of
https://github.com/movie-web/providers.git
synced 2025-09-13 18:13:25 +00:00
add simply library tests + fix umd and cjs mixup bug + simplify library paths
This commit is contained in:
1
test/README.md
Normal file
1
test/README.md
Normal file
@@ -0,0 +1 @@
|
||||
This folder is only for simple library usage tests in `CJS` and `UMD`. Real unit tests are at `src/__test__`.
|
5
test/index.js
Normal file
5
test/index.js
Normal file
@@ -0,0 +1,5 @@
|
||||
const { makeProviders, makeStandardFetcher } = require('../lib/index.umd.js');
|
||||
|
||||
const providers = makeProviders({
|
||||
fetcher: makeStandardFetcher(fetch),
|
||||
});
|
5
test/index.mjs
Normal file
5
test/index.mjs
Normal file
@@ -0,0 +1,5 @@
|
||||
import { makeProviders, makeStandardFetcher } from '../lib/index.mjs';
|
||||
|
||||
const providers = makeProviders({
|
||||
fetcher: makeStandardFetcher(fetch),
|
||||
});
|
6
test/package.json
Normal file
6
test/package.json
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"scripts": {
|
||||
"start:umd": "node index.mjs",
|
||||
"start:cjs": "node index.js"
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user