Skip to content
Snippets Groups Projects
Commit d34d281d authored by Alexander Reifschneider's avatar Alexander Reifschneider
Browse files

OZG-7619 move function

parent 5c39c056
No related branches found
No related tags found
1 merge request!64OZG-7619 Add role hints
......@@ -273,13 +273,6 @@ describe('TooltipDirective', () => {
});
describe('setWidth', () => {
function setWidthOnComponentRef(width: number): void {
directive.componentRef = Object.assign(mockComponentRef, {
location: {
nativeElement: { children: [{ getBoundingClientRect: jest.fn().mockReturnValue({ width }) }] },
},
});
}
const maxTooltipWidth: number = MAX_WIDTH * REM;
it('should set width to max width', () => {
......@@ -297,6 +290,14 @@ describe('TooltipDirective', () => {
expect(directive.componentRef.instance.width).toBe(null);
});
function setWidthOnComponentRef(width: number): void {
directive.componentRef = Object.assign(mockComponentRef, {
location: {
nativeElement: { children: [{ getBoundingClientRect: jest.fn().mockReturnValue({ width }) }] },
},
});
}
});
describe('setAutoPosition', () => {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment