From f0d97c5d00a1afdd74201688c7e22e97ffaf47f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexandre=20K=C3=BChn?= Date: Wed, 16 Sep 2020 11:04:15 +0000 Subject: [FIX] mail: do not fetch attachment style in QUnit tests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Task-2339931 closes odoo/odoo#57869 X-original-commit: 7586f7756859bb0711eee8a82bf728a039ad0d72 Signed-off-by: Alexandre Kühn (aku) --- addons/mail/static/src/js/main.js | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'addons/mail/static/src/js') diff --git a/addons/mail/static/src/js/main.js b/addons/mail/static/src/js/main.js index f8199c4dc34..d19a8edb8e9 100644 --- a/addons/mail/static/src/js/main.js +++ b/addons/mail/static/src/js/main.js @@ -71,6 +71,13 @@ Object.assign(env, { } return this.messaging.isInitialized; }, + /** + * States whether the environment is in QUnit test or not. + * + * Useful to prevent some behaviour in QUnit tests, like applying + * style of attachment that uses url. + */ + isQUnitTest: false, loadingBaseDelayDuration: 400, messaging: undefined, messagingBus: new EventBus(), -- cgit v1.2.3