Fix broken tests
This commit is contained in:
parent
318aeffcd7
commit
c63afd30ed
2 changed files with 9 additions and 9 deletions
|
@ -69,11 +69,11 @@ describe('Pipelines Nav Controls', () => {
|
|||
});
|
||||
|
||||
it('should emit postAction event when reset runner cache button is clicked', () => {
|
||||
spyOn(component, '$on');
|
||||
spyOn(component, '$emit');
|
||||
|
||||
component.$el.querySelector('.js-clear-cache').click();
|
||||
|
||||
expect(component.$on).toHaveBeenCalledWith('postAction', 'foo');
|
||||
expect(component.$emit).toHaveBeenCalledWith('resetRunnersCache', 'foo');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
|
@ -95,16 +95,16 @@ describe('Pipelines', () => {
|
|||
expect(vm.$el.querySelector('.js-pipelines-tab-all').textContent.trim()).toContain('All');
|
||||
});
|
||||
|
||||
it('renders Run Pipeline button', () => {
|
||||
it('renders Run Pipeline link', () => {
|
||||
expect(vm.$el.querySelector('.js-run-pipeline').getAttribute('href')).toEqual(paths.newPipelinePath);
|
||||
});
|
||||
|
||||
it('renders CI Lint button', () => {
|
||||
it('renders CI Lint link', () => {
|
||||
expect(vm.$el.querySelector('.js-ci-lint').getAttribute('href')).toEqual(paths.ciLintPath);
|
||||
});
|
||||
|
||||
it('renders Clear Runner Cache button', () => {
|
||||
expect(vm.$el.querySelector('.js-clear-cache').getAttribute('href')).toEqual(paths.resetCachePath);
|
||||
expect(vm.$el.querySelector('.js-clear-cache').textContent.trim()).toEqual('Clear Runner Caches');
|
||||
});
|
||||
|
||||
it('renders pipelines table', () => {
|
||||
|
@ -139,16 +139,16 @@ describe('Pipelines', () => {
|
|||
expect(vm.$el.querySelector('.js-pipelines-tab-all').textContent.trim()).toContain('All');
|
||||
});
|
||||
|
||||
it('renders Run Pipeline button', () => {
|
||||
it('renders Run Pipeline link', () => {
|
||||
expect(vm.$el.querySelector('.js-run-pipeline').getAttribute('href')).toEqual(paths.newPipelinePath);
|
||||
});
|
||||
|
||||
it('renders CI Lint button', () => {
|
||||
it('renders CI Lint link', () => {
|
||||
expect(vm.$el.querySelector('.js-ci-lint').getAttribute('href')).toEqual(paths.ciLintPath);
|
||||
});
|
||||
|
||||
it('renders Clear Runner Cache button', () => {
|
||||
expect(vm.$el.querySelector('.js-clear-cache').getAttribute('href')).toEqual(paths.resetCachePath);
|
||||
expect(vm.$el.querySelector('.js-clear-cache').textContent.trim()).toEqual('Clear Runner Caches');
|
||||
});
|
||||
|
||||
it('renders tab empty state', () => {
|
||||
|
@ -218,7 +218,7 @@ describe('Pipelines', () => {
|
|||
it('renders buttons', () => {
|
||||
expect(vm.$el.querySelector('.js-run-pipeline').getAttribute('href')).toEqual(paths.newPipelinePath);
|
||||
expect(vm.$el.querySelector('.js-ci-lint').getAttribute('href')).toEqual(paths.ciLintPath);
|
||||
expect(vm.$el.querySelector('.js-clear-cache').getAttribute('href')).toEqual(paths.resetCachePath);
|
||||
expect(vm.$el.querySelector('.js-clear-cache').textContent.trim()).toEqual('Clear Runner Caches');
|
||||
});
|
||||
|
||||
it('renders error state', () => {
|
||||
|
|
Loading…
Reference in a new issue