Skip to content

Commit d0f6061

Browse files
committed
test: fix text-area unit tests
The container element is no longer meaningful.
1 parent 13025bf commit d0f6061

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

packages/text-area/test/text-area.test.js

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -59,12 +59,11 @@ describe('text-area', () => {
5959
});
6060

6161
describe('multi-line', () => {
62-
let native, container, inputField;
62+
let native, inputField;
6363

6464
beforeEach(() => {
6565
native = textArea.inputElement;
6666
inputField = textArea.shadowRoot.querySelector('[part=input-field]');
67-
container = textArea.shadowRoot.querySelector('.vaadin-text-area-container');
6867
});
6968

7069
it('should grow height with unwrapped text', async () => {
@@ -94,23 +93,20 @@ describe('text-area', () => {
9493
await nextUpdate(textArea);
9594

9695
expect(parseFloat(window.getComputedStyle(textArea).height)).to.be.lte(100);
97-
expect(parseFloat(window.getComputedStyle(container).height)).to.be.lte(100);
9896
expect(parseFloat(window.getComputedStyle(inputField).height)).to.be.lte(100);
9997
});
10098

10199
it('should not shrink less than min-height', async () => {
102100
textArea.style.minHeight = '125px';
103101

104102
expect(window.getComputedStyle(textArea).height).to.be.equal('125px');
105-
expect(window.getComputedStyle(container).height).to.be.equal('125px');
106103
expect(parseFloat(window.getComputedStyle(inputField).height)).to.be.above(100);
107104

108105
// Check that value modification doesn't break min-height rule
109106
textArea.value = '1 row';
110107
await nextUpdate(textArea);
111108

112109
expect(window.getComputedStyle(textArea).height).to.be.equal('125px');
113-
expect(window.getComputedStyle(container).height).to.be.equal('125px');
114110
expect(parseFloat(window.getComputedStyle(inputField).height)).to.be.above(100);
115111
});
116112

@@ -119,7 +115,6 @@ describe('text-area', () => {
119115
textArea.style.maxHeight = '175px';
120116

121117
expect(window.getComputedStyle(textArea).height).to.be.equal('100px');
122-
expect(window.getComputedStyle(container).height).to.be.equal('100px');
123118

124119
// Check that value modification doesn't break min-height rule
125120
textArea.value = `
@@ -138,7 +133,6 @@ describe('text-area', () => {
138133
await nextUpdate(textArea);
139134

140135
expect(window.getComputedStyle(textArea).height).to.be.equal('175px');
141-
expect(window.getComputedStyle(container).height).to.be.equal('175px');
142136
expect(parseFloat(window.getComputedStyle(inputField).height)).to.be.above(150);
143137
});
144138

0 commit comments

Comments
 (0)