diff options
Diffstat (limited to 'test/test_helper.rb')
-rw-r--r-- | test/test_helper.rb | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/test/test_helper.rb b/test/test_helper.rb index 9d47a1b..0c22470 100644 --- a/test/test_helper.rb +++ b/test/test_helper.rb | |||
@@ -1,15 +1,15 @@ | |||
1 | # Configure Rails Environment | 1 | ENV["RAILS_ENV"] ||= "test" |
2 | ENV["RAILS_ENV"] = "test" | 2 | require_relative "../config/environment" |
3 | |||
4 | require_relative "../test/dummy/config/environment" | ||
5 | ActiveRecord::Migrator.migrations_paths = [File.expand_path("../test/dummy/db/migrate", __dir__)] | ||
6 | ActiveRecord::Migrator.migrations_paths << File.expand_path("../db/migrate", __dir__) | ||
7 | require "rails/test_help" | 3 | require "rails/test_help" |
8 | 4 | ||
9 | # Load fixtures from the engine | 5 | module ActiveSupport |
10 | if ActiveSupport::TestCase.respond_to?(:fixture_paths=) | 6 | class TestCase |
11 | ActiveSupport::TestCase.fixture_paths = [File.expand_path("fixtures", __dir__)] | 7 | # Run tests in parallel with specified workers |
12 | ActionDispatch::IntegrationTest.fixture_paths = ActiveSupport::TestCase.fixture_paths | 8 | parallelize(workers: :number_of_processors) |
13 | ActiveSupport::TestCase.file_fixture_path = File.expand_path("fixtures", __dir__) + "/files" | 9 | |
14 | ActiveSupport::TestCase.fixtures :all | 10 | # Setup all fixtures in test/fixtures/*.yml for all tests in alphabetical order. |
11 | fixtures :all | ||
12 | |||
13 | # Add more helper methods to be used by all tests here... | ||
14 | end | ||
15 | end | 15 | end |