FIX: Disable cloaking in the test environment

This commit is contained in:
Robin Ward 2016-02-24 17:43:40 -05:00
parent 0a84275800
commit 6b46092aa2
2 changed files with 3 additions and 1 deletions

View File

@ -4,7 +4,7 @@ import { Placeholder } from 'discourse/lib/posts-with-placeholders';
import { h } from 'virtual-dom';
import { addWidgetCleanCallback } from 'discourse/components/mount-widget';
const CLOAKING_ENABLED = true;
const CLOAKING_ENABLED = !window.inTestEnv;
const DAY = 1000 * 60 * 60 * 24;
let _cloaked = {};

View File

@ -41,6 +41,8 @@
//
//= require ../../public/javascripts/jquery.magnific-popup-min.js
window.inTestEnv = true;
window.assetPath = function(url) {
if (url.indexOf('defer') === 0) {
return "/assets/" + url;