✅ test: Added disabled link and anchor tag test
This commit is contained in:
parent
13dd052554
commit
672e5ec36c
|
@ -21,4 +21,16 @@ describe('VLink', () => {
|
|||
expect(a.exists()).toBe(true);
|
||||
expect(a.attributes('href')).toBe('https://example.com');
|
||||
})
|
||||
|
||||
test('disables the link when `disabled` is true', () => {
|
||||
const wrapper = mount(VLink, {
|
||||
props: {label: 'Disabled', disabled: true }
|
||||
})
|
||||
|
||||
const button = wrapper.find('.p-button');
|
||||
expect(button.classes()).toContain('disabled');
|
||||
expect(button.attributes('aria-disabled')).toBe('true');
|
||||
});
|
||||
|
||||
|
||||
})
|
||||
|
|
Loading…
Reference in New Issue
Block a user