From 9457dc55886c0da4d8c76c6b65e92336487c3ded Mon Sep 17 00:00:00 2001 From: Scott Ames-Messinger Date: Tue, 14 Apr 2020 10:34:34 -0400 Subject: [PATCH] Failing test for destroy not called on items in each Failing test for https://github.com/emberjs/ember.js/issues/18855 --- packages/@glimmer/integration-tests/test/updating-test.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/@glimmer/integration-tests/test/updating-test.ts b/packages/@glimmer/integration-tests/test/updating-test.ts index 18ad12d7f1..c91f32b6e8 100644 --- a/packages/@glimmer/integration-tests/test/updating-test.ts +++ b/packages/@glimmer/integration-tests/test/updating-test.ts @@ -1893,8 +1893,11 @@ class UpdatingTest extends RenderTest { this.rerender({ list: ['initial', 'update'] }); this.assertHTML(`
initial
update
`); + this.rerender({ list: ['initial'] }); + assert.equal(destroyCount, 1, 'destroy was called for removed item'); + this.rerender({ list: [] }); - assert.equal(destroyCount, 2, 'both list items were correctly destroyed'); + assert.equal(destroyCount, 1, 'remaining list item was correctly destroyed'); } // TODO: port https://github.com/emberjs/ember.js/pull/14082