Debian Codegraph @

test/esm/babel-runtime.js

raw
1 import assert from "assert";
2
3 export default {
4 title: "@babel/runtime",
5 testcases: [
6 [
7 "it should throw on unknown helpers",
8 () =>
9 assert.rejects(
10 async () => import("@babel/runtime/helpers/esm/unknown-helper"),
11 {
12 name: "Error",
13 code: "ERR_PACKAGE_PATH_NOT_EXPORTED",
14 }
15 ),
16 ],
17 /*[
18 "it supports importing with explicit extension",
19 () =>
20 assert.doesNotReject(
21 async () => import("@babel/runtime/helpers/esm/wrapNativeSuper.js"),
22 Error
23 ),
24 ],*/
25 [
26 "it should not throw on helpers importing internal helpers",
27 () =>
28 assert.doesNotReject(
29 async () => import("@babel/runtime/helpers/esm/wrapNativeSuper"),
30 Error
31 ),
32 ],
33 ],
34 };