decide.nolog.cz/tests/test-helper.js
renovate[bot] 98ff62af80
Update dependency prettier to v3 (#668)
* Update dependency prettier to v3

* upgrade eslint-plugin-prettier and run prettier on all files

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jeldrik Hanschke <admin@jhanschke.de>
2023-10-17 10:44:45 +02:00

23 lines
617 B
JavaScript

import Application from 'croodle/app';
import config from 'croodle/config/environment';
import * as QUnit from 'qunit';
import { setApplication } from '@ember/test-helpers';
import { setup } from 'qunit-dom';
import { start } from 'ember-qunit';
document.addEventListener(
'securitypolicyviolation',
function ({ blockedURI, violatedDirective }) {
throw new Error(
'Content-Security-Policy violation detected: ' +
`Violated directive: ${violatedDirective}. ` +
`Blocked URI: ${blockedURI}`,
);
},
);
setApplication(Application.create(config.APP));
setup(QUnit.assert);
start();