DEV: Reenable wizard test after fixing auto start for wizard qunit tests
`run-qunit.js` does not expect QUnit tests to start automatically but our wizard QUnit setup did not respect the `qunit_disable_auto_start` URL param. Hence, tests would start running automatically and when a subsequent `QUnit.start()` function call is made, we ended up getting a `QUnit.start cannot be called inside a test context.` error. This error can be consistently reproduced in the `discourse:discourse_test` container but not in the local development environment. I do not know why and did not feel like it is important at this point in time to know why.
This commit is contained in:
parent
05212f6cc3
commit
072faa08bb
|
@ -158,11 +158,10 @@ jobs:
|
|||
run: QUNIT_EMBER_CLI=0 bin/rake qunit:test['1200000']
|
||||
timeout-minutes: 30
|
||||
|
||||
# Wizard tests are failing so disabled for now while we investigate
|
||||
# - name: Wizard QUnit (Legacy)
|
||||
# if: matrix.build_type == 'frontend-legacy' && matrix.target == 'core'
|
||||
# run: QUNIT_EMBER_CLI=0 bin/rake qunit:test['600000','/wizard/qunit']
|
||||
# timeout-minutes: 10
|
||||
- name: Wizard QUnit (Legacy)
|
||||
if: matrix.build_type == 'frontend-legacy' && matrix.target == 'core'
|
||||
run: QUNIT_EMBER_CLI=0 bin/rake qunit:test['600000','/wizard/qunit']
|
||||
timeout-minutes: 10
|
||||
|
||||
- name: Plugin QUnit (Legacy)
|
||||
if: matrix.build_type == 'frontend-legacy' && matrix.target == 'plugins'
|
||||
|
|
|
@ -50,6 +50,13 @@ let createPretendServer = requirejs(
|
|||
).default;
|
||||
|
||||
let server;
|
||||
|
||||
const queryParams = new URLSearchParams(window.location.search);
|
||||
|
||||
if (queryParams.get("qunit_disable_auto_start") === "1") {
|
||||
QUnit.config.autostart = false;
|
||||
}
|
||||
|
||||
QUnit.testStart(function () {
|
||||
server = createPretendServer();
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue