spec/spec_helper.rb in reportable-1.2.0 vs spec/spec_helper.rb in reportable-1.3.0

- old
+ new

@@ -25,11 +25,17 @@ # Rails::Initializer.run(:set_autoload_paths) # Rails::Initializer.run(:initialize_time_zone) do |config| # config.time_zone = 'Pacific Time (US & Canada)' # end -FileUtils.mkdir_p File.join(File.dirname(__FILE__), 'log') -ActiveRecord::Base.logger = ActiveSupport::BufferedLogger.new(File.dirname(__FILE__) + "/log/spec.log") +# FileUtils.mkdir_p File.join(File.dirname(__FILE__), 'log') +# ActiveRecord::Base.logger = ActiveSupport::BufferedLogger.new(File.dirname(__FILE__) + "/log/spec.log") + +RSpec.configure do |config| + config.filter_run :focus => true + config.run_all_when_everything_filtered = true +end +ActiveRecord::Base.default_timezone = :local databases = YAML::load(IO.read(File.join(File.dirname(__FILE__), 'db', 'database.yml'))) ActiveRecord::Base.establish_connection(databases[ENV['DB'] || 'sqlite3']) load(File.join(File.dirname(__FILE__), 'db', 'schema.rb'))