gitlab-org--gitlab-foss/spec/javascripts/environments/environment_stop_spec.js.es6

20 lines
566 B
JavaScript
Raw Normal View History

//= require vue
//= require environments/components/environment_stop
describe('Stop Component', () => {
fixture.preload('environments/element.html');
beforeEach(() => {
fixture.load('environments/element.html');
});
it('should link to the provided URL', () => {
2016-11-18 17:02:09 -05:00
const stopURL = '/stop';
const component = new window.gl.environmentsList.StopComponent({
el: document.querySelector('.test-dom-element'),
propsData: {
stop_url: stopURL,
},
});
2016-11-18 17:02:09 -05:00
expect(component.$el.getAttribute('href')).toEqual(stopURL);
});
});