diff --git a/packages/elements/src/tree/__test__/tree.test.js b/packages/elements/src/tree/__test__/tree.test.js index 890504a5ee..810be3e802 100644 --- a/packages/elements/src/tree/__test__/tree.test.js +++ b/packages/elements/src/tree/__test__/tree.test.js @@ -78,13 +78,13 @@ describe('tree/Tree', () => { await elementUpdated(el); const firstElementIcon = el.children[0].shadowRoot.querySelector('[part="label-icon"]'); - expect(firstElementIcon.attributes.src.value).to.equal('info'); + expect(firstElementIcon.attributes.icon.value).to.equal('info'); const secondElementIcon = el.children[1].shadowRoot.querySelector('[part="label-icon"]'); - expect(secondElementIcon.attributes.src.value).to.equal(''); + expect(secondElementIcon.attributes.icon.value).to.equal(''); const thirdElementIcon = el.children[2].shadowRoot.querySelector('[part="label-icon"]'); - expect(thirdElementIcon.attributes.src.value).to.equal('https://cdn.refinitiv.com/public/libs/elf/assets/elf-theme-halo/resources/icons/favorites.svg'); + expect(thirdElementIcon.attributes.icon.value).to.equal('https://cdn.refinitiv.com/public/libs/elf/assets/elf-theme-halo/resources/icons/favorites.svg'); const forthElementIcon = el.children[3].shadowRoot.querySelector('[part="label-icon"]'); expect(forthElementIcon).to.equal(null); @@ -100,17 +100,17 @@ describe('tree/Tree', () => { el.composer.setItemPropertyValue(el.manager.visibleItems[0], 'icon', ''); await elementUpdated(el); await nextFrame(); - expect(iconElement.attributes.src.value).to.equal(''); + expect(iconElement.attributes.icon.value).to.equal(''); el.composer.setItemPropertyValue(el.manager.visibleItems[0], 'icon', 'https://cdn.refinitiv.com/public/libs/elf/assets/elf-theme-halo/resources/icons/favorites.svg'); await elementUpdated(el); await nextFrame(); - expect(iconElement.attributes.src.value).to.equal('https://cdn.refinitiv.com/public/libs/elf/assets/elf-theme-halo/resources/icons/favorites.svg'); + expect(iconElement.attributes.icon.value).to.equal('https://cdn.refinitiv.com/public/libs/elf/assets/elf-theme-halo/resources/icons/favorites.svg'); el.composer.setItemPropertyValue(el.manager.visibleItems[0], 'icon', 'buzz'); await elementUpdated(el); await nextFrame(); - expect(iconElement.attributes.src.value).to.equal('buzz'); + expect(iconElement.attributes.icon.value).to.equal('buzz'); el.composer.setItemPropertyValue(el.manager.visibleItems[0], 'icon', undefined); await elementUpdated(el);