2017-08-14 13:08:09 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2012-05-07 00:36:59 -04:00
|
|
|
ENV["RAILS_ENV"] ||= "test"
|
|
|
|
|
2016-08-06 13:16:09 -04:00
|
|
|
require "stringio"
|
|
|
|
require "active_support/testing/autorun"
|
|
|
|
require "active_support/testing/stream"
|
|
|
|
require "fileutils"
|
2009-02-03 21:25:37 -05:00
|
|
|
|
2016-08-06 13:16:09 -04:00
|
|
|
require "active_support"
|
|
|
|
require "action_controller"
|
|
|
|
require "action_view"
|
|
|
|
require "rails/all"
|
2009-09-25 23:54:41 -04:00
|
|
|
|
2010-09-23 13:13:07 -04:00
|
|
|
module TestApp
|
|
|
|
class Application < Rails::Application
|
2017-05-15 10:17:28 -04:00
|
|
|
config.root = __dir__
|
2010-09-23 13:13:07 -04:00
|
|
|
end
|
2009-10-19 22:22:23 -04:00
|
|
|
end
|
2014-01-13 06:24:06 -05:00
|
|
|
|
2014-07-15 16:56:27 -04:00
|
|
|
class ActiveSupport::TestCase
|
2015-01-15 01:42:33 -05:00
|
|
|
include ActiveSupport::Testing::Stream
|
2017-01-17 04:50:53 -05:00
|
|
|
|
2018-09-22 07:45:29 -04:00
|
|
|
private
|
|
|
|
# Skips the current run on Rubinius using Minitest::Assertions#skip
|
|
|
|
def rubinius_skip(message = "")
|
|
|
|
skip message if RUBY_ENGINE == "rbx"
|
|
|
|
end
|
|
|
|
|
|
|
|
# Skips the current run on JRuby using Minitest::Assertions#skip
|
|
|
|
def jruby_skip(message = "")
|
|
|
|
skip message if defined?(JRUBY_VERSION)
|
|
|
|
end
|
2014-07-15 16:56:27 -04:00
|
|
|
end
|
2019-03-24 13:59:28 -04:00
|
|
|
|
|
|
|
require_relative "../../tools/test_common"
|