diff --git a/test/runtime/samples/nested-transition-if-block-not-remounted/Span.html b/test/runtime/samples/nested-transition-if-block-not-remounted/Span.html new file mode 100644 index 0000000000..b16b370950 --- /dev/null +++ b/test/runtime/samples/nested-transition-if-block-not-remounted/Span.html @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/test/runtime/samples/nested-transition-if-block-not-remounted/_config.js b/test/runtime/samples/nested-transition-if-block-not-remounted/_config.js new file mode 100644 index 0000000000..128a518134 --- /dev/null +++ b/test/runtime/samples/nested-transition-if-block-not-remounted/_config.js @@ -0,0 +1,26 @@ +export default { + data: { + x: true, + value: 'one' + }, + + html: ` +
+ + x +
+ `, + + nestedTransitions: true, + + test(assert, component, target, window, raf) { + const div = target.querySelector('div'); + const { appendChild, insertBefore } = div; + + div.appendChild = div.insertBefore = () => { + throw new Error('DOM was mutated'); + }; + + component.set({ value: 'two' }); + }, +}; diff --git a/test/runtime/samples/nested-transition-if-block-not-remounted/main.html b/test/runtime/samples/nested-transition-if-block-not-remounted/main.html new file mode 100644 index 0000000000..ad8b2454a8 --- /dev/null +++ b/test/runtime/samples/nested-transition-if-block-not-remounted/main.html @@ -0,0 +1,14 @@ +
+ {#if x} + + x + {/if} +
+ + \ No newline at end of file