(elements: any[])
| 915 | } |
| 916 | |
| 917 | function expectNoStickyStyles(elements: any[]) { |
| 918 | elements.forEach(element => { |
| 919 | expect(element.classList.contains('cdk-table-sticky')).toBe(false); |
| 920 | expectStickyBorderClass(element); |
| 921 | expect(element.style.position).toBe(''); |
| 922 | expect(element.style.zIndex || '0').toBe('0'); |
| 923 | ['top', 'bottom', 'left', 'right'].forEach(d => { |
| 924 | expect(element.style[d] || 'unset') |
| 925 | .withContext(`Expected ${d} to be unset`) |
| 926 | .toBe('unset'); |
| 927 | }); |
| 928 | }); |
| 929 | } |
| 930 | |
| 931 | function expectStickyStyles(element: any, zIndex: string, directions: PositionDirections = {}) { |
| 932 | expect(element.style.position).toContain('sticky'); |
no test coverage detected