From 27f9906b1edd5d6acb779630ca90d338603956c0 Mon Sep 17 00:00:00 2001 From: Peter 'Pita' Martischka Date: Mon, 8 Oct 2012 14:07:08 +0200 Subject: [PATCH] ensure we don't inject a second jquery --- tests/frontend/helper.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/frontend/helper.js b/tests/frontend/helper.js index 196414a9f..ec4bd19c8 100644 --- a/tests/frontend/helper.js +++ b/tests/frontend/helper.js @@ -7,7 +7,8 @@ var helper = {}; $iframeContainer = $("#iframe-container"); $.get('/static/js/jquery.js').done(function(code){ - jsLibraries["jquery"] = code; + // make sure we don't override existing jquery + jsLibraries["jquery"] = "if(typeof $ === 'undefined') {\n" + code + "\n}"; $.get('/tests/frontend/sendkeys.js').done(function(code){ jsLibraries["sendkeys"] = code;