From 16969e1d5a9acfee66f0ff8f409e2a97404d8d29 Mon Sep 17 00:00:00 2001 From: Scott Erickson <sderickson@gmail.com> Date: Fri, 19 Feb 2016 13:50:00 -0800 Subject: [PATCH] Fix Travis tests --- app/assets/javascripts/run-tests.js | 5 +++-- app/assets/main.html | 3 +++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/app/assets/javascripts/run-tests.js b/app/assets/javascripts/run-tests.js index bcf712b49..1463c3f60 100644 --- a/app/assets/javascripts/run-tests.js +++ b/app/assets/javascripts/run-tests.js @@ -2,8 +2,9 @@ // Hooks into the test view logic for running tests. -window.userObject = {_id:'1'} -window.StripeCheckout = {configure: function (){}} +window.userObject = {_id:'1'}; +window.serverConfig = {picoCTF: false, production: false}; +window.StripeCheckout = {configure: function (){}}; initialize = require('core/initialize'); initialize.init(); console.debug = function() {}; // Karma conf doesn't seem to work? Debug messages are still emitted when they shouldn't be. diff --git a/app/assets/main.html b/app/assets/main.html index d676b8804..8e04573cb 100644 --- a/app/assets/main.html +++ b/app/assets/main.html @@ -75,6 +75,9 @@ <![endif]> <script> + // IMPORTANT: If you edit here, make sure app/assets/javascripts/run-tests.js puts in placeholders for + // running client tests on Travis. + // Placeholder for iPad, which inspects the user object at the bottom of an injected page. window.serverConfig = "serverConfigTag"; window.userObject = "userObjectTag";