From af0557a2d41e468e98f179607693eba28c652e2e Mon Sep 17 00:00:00 2001 From: Mike Lewis Date: Thu, 24 Oct 2019 13:45:03 +0100 Subject: [PATCH] add regression test for missing class on elem with bind and spread (#3668) relates to #2707 --- .../class-with-spread-and-bind/_config.js | 18 ++++++++++++++++++ .../class-with-spread-and-bind/main.svelte | 11 +++++++++++ 2 files changed, 29 insertions(+) create mode 100644 test/runtime/samples/class-with-spread-and-bind/_config.js create mode 100644 test/runtime/samples/class-with-spread-and-bind/main.svelte diff --git a/test/runtime/samples/class-with-spread-and-bind/_config.js b/test/runtime/samples/class-with-spread-and-bind/_config.js new file mode 100644 index 0000000000..f3c54e8c52 --- /dev/null +++ b/test/runtime/samples/class-with-spread-and-bind/_config.js @@ -0,0 +1,18 @@ +export default { + props: { + primary: true, + }, + + html: `
`, + + test({ assert, component, target, window }) { + component.primary = true; + + assert.htmlEqual( + target.innerHTML, + ` +
+ ` + ); + }, +}; diff --git a/test/runtime/samples/class-with-spread-and-bind/main.svelte b/test/runtime/samples/class-with-spread-and-bind/main.svelte new file mode 100644 index 0000000000..c7c24a2e7b --- /dev/null +++ b/test/runtime/samples/class-with-spread-and-bind/main.svelte @@ -0,0 +1,11 @@ + + +