auto_test 0.1.7 → 0.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/auto_test/version.rb +1 -1
- data/lib/tasks/auto_test.rb +6 -8
- metadata +1 -1
data/lib/auto_test/version.rb
CHANGED
data/lib/tasks/auto_test.rb
CHANGED
@@ -5,17 +5,15 @@ namespace :auto_test do
|
|
5
5
|
puts "Running auto_test..."
|
6
6
|
sh "rails server -e test -p 3002 -d"
|
7
7
|
path = %x(gem which auto_test)
|
8
|
-
path = path[0..path.size-
|
9
|
-
sh "rspec '#{path}
|
10
|
-
sh "rm '#{path}
|
8
|
+
path = path[0..path.size-15]
|
9
|
+
sh "rspec '#{path}/spec/requests/auto_spec.rb' -o '#{path}/../../log/rspec.txt'"
|
10
|
+
sh "rm '#{path}/../log/rspec.txt'"
|
11
11
|
Rake::Task["auto_test:error_calc"].invoke
|
12
12
|
Rake::Task["auto_test:stop"].invoke
|
13
13
|
end
|
14
14
|
|
15
15
|
desc "calculating the errors"
|
16
16
|
task :error_calc do
|
17
|
-
path = %x(gem which auto_test)
|
18
|
-
path = path[0..path.size-13]
|
19
17
|
err = File.read("#{Rails.root}/log/errors.log")
|
20
18
|
if err.to_i > 0 then
|
21
19
|
puts "Do you want to see the error-path in firefox? Type yes/no:"
|
@@ -29,10 +27,10 @@ namespace :auto_test do
|
|
29
27
|
desc "Reducing the error path"
|
30
28
|
task :reduce_errors do
|
31
29
|
path = %x(gem which auto_test)
|
32
|
-
path = path[0..path.size-
|
30
|
+
path = path[0..path.size-15]
|
33
31
|
puts "Reducing the error path, this could take a while..."
|
34
|
-
sh "rspec #{path}
|
35
|
-
sh "rm '#{path}
|
32
|
+
sh "rspec #{path}/spec/requests/error_reduction_spec.rb -o '#{path}/../../log/reduce_err.txt'"
|
33
|
+
sh "rm '#{path}/../log/reduce_err.txt'"
|
36
34
|
Rake::Task["auto_test:start_action_path"].invoke
|
37
35
|
end
|
38
36
|
|