Attempt workaround for failing theme asset specs

Signed-off-by: Alex Coles <alex@alexbcoles.com>
pull/1292/head
Alex Coles 11 years ago
parent 10b6edd8f3
commit b0f758fce2
  1. 21
      config/initializers/10-patches.rb

@ -27,6 +27,27 @@
# See doc/COPYRIGHT.rdoc for more details.
#++
require 'sprockets/rails'
module Sprockets
module Rails
# Workaround to ensure some asset helpers (like #image_path) use the
# correct asset prefix.
# Helps OpenProject::Themes::ViewHelpers# find theme assets.
# NOTE: repercussions of this hack are unknown.
module LegacyAssetUrlHelper
ASSET_PUBLIC_DIRECTORIES.replace({
:audio => '/assets',
:font => '/assets',
:image => '/assets',
:javascript => '/assets',
:stylesheet => '/assets',
:video => '/assets'
})
end
end
end
require 'active_record'
module ActiveRecord

Loading…
Cancel
Save