diff --git a/app/overrides/set_auth_token_in_test.rb b/app/overrides/set_auth_token_in_test.rb new file mode 100644 index 0000000000..eb1b7128b3 --- /dev/null +++ b/app/overrides/set_auth_token_in_test.rb @@ -0,0 +1,9 @@ +Deface::Override.new(:virtual_path => "spree/layouts/spree_application", + :insert_bottom => "[data-hook='inside_head']", + :partial => "layouts/auth_token_script", + :name => "auth_token_script") + +Deface::Override.new(:virtual_path => "spree/layouts/admin", + :insert_bottom => "[data-hook='admin_inside_head']", + :partial => "layouts/auth_token_script", + :name => "auth_token_script") diff --git a/app/views/layouts/_auth_token_script.html.haml b/app/views/layouts/_auth_token_script.html.haml new file mode 100644 index 0000000000..bc0f6c8dc4 --- /dev/null +++ b/app/views/layouts/_auth_token_script.html.haml @@ -0,0 +1,4 @@ +:javascript + if(typeof AUTH_TOKEN === 'undefined') { + var AUTH_TOKEN = ''; + }