Precise DOM morphing
morphing typescript dom
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Add final nanomorph tests

+36
+36
test/something.test.js
··· 718 718 expect(a.outerHTML).to.equal(b.outerHTML); 719 719 }) 720 720 }); 721 + 722 + it('allows morphing from Node to NodeList', async () => { 723 + const a = await fixture(html`<div><div>a</div></div>`); 724 + const b = await fixture(html`<div>a</div><div>b</div>`); 725 + 726 + morph(a, b); 727 + 728 + expect(a.outerHTML).to.equal(b.outerHTML); 729 + }) 730 + 731 + it('allows morphing from NodeList to Node', async () => { 732 + const a = await fixture(html`<div>a</div><div>b</div>`); 733 + const b = await fixture(html`<div><div>a</div></div>`); 734 + 735 + morph(a, b); 736 + 737 + expect(a.outerHTML).to.equal(b.outerHTML); 738 + }) 739 + 740 + it('allows morphing from NodeList to NodeList', async () => { 741 + const a = await fixture(html`<div>a</div><div>b</div>`); 742 + const b = await fixture(html`<div>z</div><div>y</div>`); 743 + 744 + morph(a, b); 745 + 746 + expect(a.outerHTML).to.equal(b.outerHTML); 747 + }) 748 + 749 + it('allows morphing from Node to Node', async () => { 750 + const a = await fixture(html`<div><div>a</div></div>`); 751 + const b = await fixture(html`<div><div>b</div></div>`); 752 + 753 + morph(a, b); 754 + 755 + expect(a.outerHTML).to.equal(b.outerHTML); 756 + }) 721 757 });