forked from rails-sqlserver/activerecord-sqlserver-adapter
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Rakefile
41 lines (35 loc) · 996 Bytes
/
Rakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# frozen_string_literal: true
require "bundler/gem_tasks"
require "rake/testtask"
require_relative "test/support/paths_sqlserver"
require_relative "test/support/rake_helpers"
task test: ["test:dblib"]
task default: [:test]
namespace :test do
%w(dblib).each do |mode|
Rake::TestTask.new(mode) do |t|
t.libs = ARTest::SQLServer.test_load_paths
t.test_files = test_files
t.warning = !!ENV["WARNING"]
t.verbose = false
end
end
task "dblib:env" do
ENV["ARCONN"] = "dblib"
end
end
task "test:dblib" => "test:dblib:env"
namespace :profile do
["dblib"].each do |mode|
namespace mode.to_sym do
Dir.glob("test/profile/*_profile_case.rb").sort.each do |test_file|
profile_case = File.basename(test_file).sub("_profile_case.rb", "")
Rake::TestTask.new(profile_case) do |t|
t.libs = ARTest::SQLServer.test_load_paths
t.test_files = [test_file]
t.verbose = true
end
end
end
end
end