From 990f5721105adf721e4fa6a46748e87838b8963b Mon Sep 17 00:00:00 2001 From: Mathias Picker Date: Thu, 7 Jul 2022 09:27:55 +0200 Subject: [PATCH] review fixes --- src/compiler/parse/state/tag.ts | 2 -- .../_config.js | 3 ++- .../main.svelte | 0 test/runtime/samples/textarea-crazy-value-attribute/_config.js | 3 ++- 4 files changed, 4 insertions(+), 4 deletions(-) rename test/runtime/samples/{input-crazy-value-attribute => input-crazy-value-attribute.solo}/_config.js (67%) rename test/runtime/samples/{input-crazy-value-attribute => input-crazy-value-attribute.solo}/main.svelte (100%) diff --git a/src/compiler/parse/state/tag.ts b/src/compiler/parse/state/tag.ts index 219e14ca33..3ed65940f2 100644 --- a/src/compiler/parse/state/tag.ts +++ b/src/compiler/parse/state/tag.ts @@ -165,9 +165,7 @@ export default function tag(parser: Parser) { }; } - const unique_names: Set = new Set(); - let attribute; while ((attribute = read_attribute(parser, unique_names))) { element.attributes.push(attribute); diff --git a/test/runtime/samples/input-crazy-value-attribute/_config.js b/test/runtime/samples/input-crazy-value-attribute.solo/_config.js similarity index 67% rename from test/runtime/samples/input-crazy-value-attribute/_config.js rename to test/runtime/samples/input-crazy-value-attribute.solo/_config.js index 415497c670..31cbbd27d9 100644 --- a/test/runtime/samples/input-crazy-value-attribute/_config.js +++ b/test/runtime/samples/input-crazy-value-attribute.solo/_config.js @@ -5,6 +5,7 @@ export default { test({ assert, target }) { const input = target.querySelector('input'); - assert.equal(input.value.length > 100_000, true); + const one_million = 1000000 + assert.equal(input.value.length > one_million, true); } }; diff --git a/test/runtime/samples/input-crazy-value-attribute/main.svelte b/test/runtime/samples/input-crazy-value-attribute.solo/main.svelte similarity index 100% rename from test/runtime/samples/input-crazy-value-attribute/main.svelte rename to test/runtime/samples/input-crazy-value-attribute.solo/main.svelte diff --git a/test/runtime/samples/textarea-crazy-value-attribute/_config.js b/test/runtime/samples/textarea-crazy-value-attribute/_config.js index e0f6a960f0..11f0eef400 100644 --- a/test/runtime/samples/textarea-crazy-value-attribute/_config.js +++ b/test/runtime/samples/textarea-crazy-value-attribute/_config.js @@ -5,6 +5,7 @@ export default { test({ assert, target }) { const textarea = target.querySelector('textarea'); - assert.equal(textarea.value.length > 100_000, true); + const one_million = 1000000 + assert.equal(textarea.value.length > one_million, true); } };