2fb167fa3b
From https://gitlab.com/gitlab-org/gitlab-ce/issues/36760 Was reverted in https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/14373
30 lines
960 B
JavaScript
30 lines
960 B
JavaScript
import domContentLoaded from '~/feature_highlight/feature_highlight_options';
|
|
import bp from '~/breakpoints';
|
|
|
|
describe('feature highlight options', () => {
|
|
describe('domContentLoaded', () => {
|
|
it('should not call highlightFeatures when breakpoint is xs', () => {
|
|
spyOn(bp, 'getBreakpointSize').and.returnValue('xs');
|
|
|
|
expect(domContentLoaded()).toBe(false);
|
|
});
|
|
|
|
it('should not call highlightFeatures when breakpoint is sm', () => {
|
|
spyOn(bp, 'getBreakpointSize').and.returnValue('sm');
|
|
|
|
expect(domContentLoaded()).toBe(false);
|
|
});
|
|
|
|
it('should not call highlightFeatures when breakpoint is md', () => {
|
|
spyOn(bp, 'getBreakpointSize').and.returnValue('md');
|
|
|
|
expect(domContentLoaded()).toBe(false);
|
|
});
|
|
|
|
it('should call highlightFeatures when breakpoint is lg', () => {
|
|
spyOn(bp, 'getBreakpointSize').and.returnValue('lg');
|
|
|
|
expect(domContentLoaded()).toBe(true);
|
|
});
|
|
});
|
|
});
|