Skip to content
This repository was archived by the owner on Jan 10, 2024. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion lib/jasmine_rails/offline_asset_paths.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,13 @@ def compute_public_path_with_offline_asset(source, dir, options={})

FileUtils.mkdir_p File.dirname(source_path)
Rails.logger.debug "Compiling #{source} to #{source_path}"
File.open(source_path, 'w') {|f| f << content }
File.open(source_path, 'w') do |f|
if Rails::VERSION::MAJOR == 4 && !Rails.env.test? && source == 'jasmine-specs.js'
f << ''
else
f << content
end
end
"/assets/#{source}"
end

Expand Down