Skip to content

Commit 2b57dce

Browse files
Pontus LundinPontus Lundin
Pontus Lundin
authored and
Pontus Lundin
committed
fix module resolving in custom element test
1 parent b8ce987 commit 2b57dce

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

test/custom-elements/index.ts

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,9 @@ describe('custom-elements', function() {
6363

6464
const solo = /\.solo$/.test(dir);
6565
const skip = /\.skip$/.test(dir);
66+
const easing = path.resolve('easing/index.mjs');
6667
const internal = path.resolve('internal/index.mjs');
68+
const transition = path.resolve('transition/index.mjs');
6769
const index = path.resolve('index.mjs');
6870
const warnings = [];
6971

@@ -76,10 +78,18 @@ describe('custom-elements', function() {
7678
plugins: [
7779
{
7880
resolveId(importee) {
79-
if (importee === 'svelte/internal' || importee === './internal') {
81+
if (importee === '../easing') {
82+
return easing;
83+
}
84+
85+
if (importee === 'svelte/internal' || importee === './internal' || importee === '../internal') {
8086
return internal;
8187
}
8288

89+
if (importee === 'svelte/transition' || importee === './transition') {
90+
return transition;
91+
}
92+
8393
if (importee === 'svelte') {
8494
return index;
8595
}

0 commit comments

Comments
 (0)