Last active
August 31, 2020 06:46
-
-
Save IAfanasov/9d55b485391ff010e229e436637c8332 to your computer and use it in GitHub Desktop.
non-atomic-test.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
it('should use requested position', () => { | |
const fixture = createTestComponent(`<div ngbTooltip="Great tip!" placement="left"></div>`); | |
const directive = fixture.debugElement.query(By.directive(NgbTooltip)); | |
triggerEvent(directive, 'mouseenter'); | |
fixture.detectChanges(); | |
const windowEl = getWindow(fixture.nativeElement); | |
expect(windowEl).toHaveCssClass('tooltip'); | |
expect(windowEl).toHaveCssClass('bs-tooltip-left'); | |
expect(windowEl.textContent.trim()).toBe('Great tip!'); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment