How to use the @uipath/angular/testing.EventGenerator.dragLeave function in @uipath/angular

To help you get started, we’ve selected a few @uipath/angular examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github UiPath / angular-components / projects / angular / directives / ui-drag-and-drop-file / src / ui-drag-and-drop-file.directive.spec.ts View on Github external
it('should remove class on drag-leave', () => {
            container.dispatchEvent(EventGenerator.dragOver);

            fixture.detectChanges();

            expect(container.classList.contains(appliedClass)).toBeTruthy();

            container.dispatchEvent(EventGenerator.dragLeave);
            fixture.detectChanges();

            expect(container.classList.contains(appliedClass)).toBeFalsy();
        });