Skip to content

Commit 12ad1ed

Browse files
committed
fix(picker-column-option): fixing tests
1 parent 131de8b commit 12ad1ed

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

core/src/components/picker-column-option/test/picker-column-option.spec.ts

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { newSpecPage } from '@stencil/core/testing';
33
import { PickerColumnOption } from '../picker-column-option';
44

55
describe('picker column option', () => {
6-
it('button should be enabled by default', async () => {
6+
it('should be enabled by default', async () => {
77
const page = await newSpecPage({
88
components: [PickerColumnOption],
99
html: `
@@ -12,12 +12,11 @@ describe('picker column option', () => {
1212
});
1313

1414
const option = page.body.querySelector('ion-picker-column-option')!;
15-
const button = option.shadowRoot!.querySelector('button')!;
1615

17-
await expect(button.hasAttribute('disabled')).toEqual(false);
16+
await expect(option.classList.contains('option-disabled')).toEqual(false);
1817
});
1918

20-
it('button should be disabled if specified', async () => {
19+
it('should be disabled if specified', async () => {
2120
const page = await newSpecPage({
2221
components: [PickerColumnOption],
2322
html: `
@@ -26,8 +25,7 @@ describe('picker column option', () => {
2625
});
2726

2827
const option = page.body.querySelector('ion-picker-column-option')!;
29-
const button = option.shadowRoot!.querySelector('button')!;
3028

31-
await expect(button.hasAttribute('disabled')).toEqual(true);
29+
await expect(option.classList.contains('option-disabled')).toEqual(true);
3230
});
3331
});

0 commit comments

Comments
 (0)