Compare commits

..

1 Commits

Author SHA1 Message Date
Romain Beauxis
57c035f06a Added gem_assets config. 2012-12-12 15:25:26 -06:00
3 changed files with 18 additions and 5 deletions

View File

@ -1,4 +1,4 @@
_This project is dead. You should use [Karma](http://karma-runner.github.io/) instead. I do._ _I am looking for a new maintainer for this project. Please contact me via GitHub if you're interested._
# Jasmine Headless WebKit runner # Jasmine Headless WebKit runner

View File

@ -23,10 +23,6 @@
#include "Runner.h" #include "Runner.h"
#if QT_VERSION >= QT_VERSION_CHECK(4, 8, 0)
#include <getopt.h>
#endif
#if QT_VERSION < QT_VERSION_CHECK(4, 7, 0) #if QT_VERSION < QT_VERSION_CHECK(4, 7, 0)
#error Use Qt 4.7 or later version #error Use Qt 4.7 or later version
#endif #endif

View File

@ -1,6 +1,7 @@
require 'jasmine-core' require 'jasmine-core'
require 'time' require 'time'
require 'multi_json' require 'multi_json'
require 'rubygems'
require 'set' require 'set'
require 'sprockets' require 'sprockets'
require 'sprockets/engines' require 'sprockets/engines'
@ -130,8 +131,14 @@ module Jasmine::Headless
@search_paths += src_dir.collect { |dir| File.expand_path(dir) } @search_paths += src_dir.collect { |dir| File.expand_path(dir) }
@search_paths += asset_paths.collect { |dir| File.expand_path(dir) } @search_paths += asset_paths.collect { |dir| File.expand_path(dir) }
@search_paths += spec_dir.collect { |dir| File.expand_path(dir) } @search_paths += spec_dir.collect { |dir| File.expand_path(dir) }
@search_paths += gem_assets.collect do |name, dirs|
dirs.collect do |dir|
File.expand_path(File.join(gem_dir(name), dir))
end
end.flatten
@search_paths.uniq! @search_paths.uniq!
@search_paths @search_paths
end end
@ -291,6 +298,10 @@ module Jasmine::Headless
@asset_paths ||= config_dir('asset_paths') @asset_paths ||= config_dir('asset_paths')
end end
def gem_assets
@gem_assets ||= @options[:config]['gem_assets']
end
def spec_file_searches def spec_file_searches
@searches['spec_files'] @searches['spec_files']
end end
@ -320,6 +331,12 @@ module Jasmine::Headless
def spec_helper def spec_helper
File.join(spec_dir, "helpers", "spec_helper") File.join(spec_dir, "helpers", "spec_helper")
end end
def gem_dir gem
return unless gemspec = Gem.loaded_specs[gem]
gemspec.gem_dir
end
end end
end end