Precise DOM morphing
morphing typescript dom
0
fork

Configure Feed

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

Add more nanomorph test cases

+20
+20
test/something.test.js
··· 463 463 }); 464 464 }) 465 465 }); 466 + 467 + describe("lists", () => { 468 + it("should append nodes", async () => { 469 + const a = await fixture(html`<ul></ul>`); 470 + const b = await fixture(html`<ul><li>1</li><li>2</li><li>3</li><li>4</li><li>5</li></ul>`); 471 + 472 + morph(a, b); 473 + 474 + expect(a.outerHTML).to.equal(b.outerHTML); 475 + }); 476 + 477 + it("should remove nodes", async () => { 478 + const a = await fixture(html`<ul><li>1</li><li>2</li><li>3</li><li>4</li><li>5</li></ul>`); 479 + const b = await fixture(html`<ul></ul>`); 480 + 481 + morph(a, b); 482 + 483 + expect(a.outerHTML).to.equal(b.outerHTML); 484 + }); 485 + }); 466 486 });