kiwix-js icon indicating copy to clipboard operation
kiwix-js copied to clipboard

Re-enable Unit Tests on IE11

Open Jaifroid opened this issue 2 years ago • 3 comments

This arises from #736. Having polyfilled Promises, it should now be possible to re-enable (online) Unit Tests on IE11. #736 fixes local (browser-run) tests for IE11, so there is no reason, on the face of it, why they should not be able to run automatically as well, assuming Sauce Labs provides an IE11 instance.

Jaifroid avatar Jul 22 '21 07:07 Jaifroid

SauceLabs does provide an IE11 instance (and even older versions : https://saucelabs.com/resources/articles/testing-on-internet-explorer). And we already run the UI tests on IE11.

It should only be a matter of uncommenting line 63 in tests/karma.conf.saucelabs.js (and pray for a good result)

mossroy avatar Jul 22 '21 16:07 mossroy

When running the tests locally on IE11 (on the Promise Polyfill PR), only 16 out of the 22 tests run (it is as if the other 6 tests don't exist: there is no failure). I could not see anything in tests.js that prevents tests from running. Perhaps there is a configuration somewhere?

Jaifroid avatar Jul 22 '21 17:07 Jaifroid

This blog could be useful if we ever want to run tests on Internet Exploerer via GitHub actions in a Windows-latest instance:. This uses IE Mode in Edge:

https://blogs.windows.com/msedgedev/2022/02/01/test-ie-mode-in-microsoft-edge-internet-explorer-driver/

The examples use Selenium, but it's not required, and other frameworks can be used.

Jaifroid avatar Feb 10 '22 07:02 Jaifroid

I've re-enabled End-to-end tests with IE11 Mode for Edge. These now run on GitHub actions. It's not possible to re-enable Unit tests, because these now use ES6 modules which IE11 doesn't support. However, automatic e2e tests seem like a better way of testing IE11 compatibility in any case. So we can close this now.

Jaifroid avatar Aug 10 '23 13:08 Jaifroid