Fix sidebar_detail_row_spec.js
This commit is contained in:
parent
12401758a4
commit
4c3482345a
1 changed files with 16 additions and 12 deletions
|
@ -38,10 +38,13 @@ describe('Sidebar detail row', () => {
|
|||
).toEqual('this is the title: this is the value');
|
||||
});
|
||||
|
||||
it('should not render help when helpUrl not provided', () => {
|
||||
expect(vm.$el.querySelector('.help-button')).toBeUndefined();
|
||||
describe('when helpUrl not provided', () => {
|
||||
it('should not render help', () => {
|
||||
expect(vm.$el.querySelector('.help-button')).toBeNull();
|
||||
});
|
||||
});
|
||||
|
||||
describe('when helpUrl provided', () => {
|
||||
beforeEach(() => {
|
||||
vm = new SidebarDetailRow({
|
||||
propsData: {
|
||||
|
@ -51,7 +54,8 @@ describe('Sidebar detail row', () => {
|
|||
}).$mount();
|
||||
});
|
||||
|
||||
it('should render help when helpUrl is provided', () => {
|
||||
it('should render help', () => {
|
||||
expect(vm.$el.querySelector('.help-button a').getAttribute('href')).toEqual('help url');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue