moto 0.0.24 → 0.0.25
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.
- checksums.yaml +4 -4
- data/bin/moto +5 -5
- data/lib/app_generator.rb +76 -5
- data/lib/empty_listener.rb +16 -16
- data/lib/exceptions/moto.rb +6 -6
- data/lib/exceptions/test_forced_failure.rb +6 -6
- data/lib/exceptions/test_forced_passed.rb +6 -6
- data/lib/exceptions/test_skipped.rb +6 -6
- data/lib/forward_context_methods.rb +20 -20
- data/lib/initializer.rb +6 -6
- data/lib/listeners/base.rb +25 -25
- data/lib/listeners/console.rb +28 -28
- data/lib/listeners/console_dots.rb +62 -62
- data/lib/listeners/junit_xml.rb +36 -36
- data/lib/parser.rb +43 -12
- data/lib/result.rb +83 -83
- data/lib/runner_logging.rb +26 -26
- data/lib/test_logging.rb +48 -48
- data/lib/version.rb +1 -1
- metadata +25 -25
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d2eb8efa5d64b6f20b2ce57c06b47105d16a8a0d
|
4
|
+
data.tar.gz: 6c0024378bf4157fcd64a7b8c256f93eb57aef6c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9ae78b549ab8f886092296e5556b041888c6ea60bbf5516e9666dd3f3eaab4f2fda5fd5a4a0f1e096edd1a73f9e8baef7f5eb2b96b3cacb856355f0064833492
|
7
|
+
data.tar.gz: 5b1d85e5737de49867d88f4ae5f7b1c45bb8d469558a6cef965a5b949ebfce65771633fea20913915cb6f02033d5392abb0227fa4d9f919790ab8fcc5ca92d89
|
data/bin/moto
CHANGED
@@ -1,5 +1,5 @@
|
|
1
|
-
#!/usr/bin/env ruby
|
2
|
-
|
3
|
-
require_relative '../lib/parser'
|
4
|
-
|
5
|
-
Moto::Parser.run ARGV
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
require_relative '../lib/parser'
|
4
|
+
|
5
|
+
Moto::Parser.run ARGV
|
data/lib/app_generator.rb
CHANGED
@@ -1,9 +1,80 @@
|
|
1
|
+
require 'fileutils'
|
2
|
+
|
1
3
|
module Moto
|
2
4
|
class AppGenerator
|
3
|
-
|
4
|
-
|
5
|
-
|
5
|
+
|
6
|
+
# Creates directories and file with class template for a test.
|
7
|
+
# @param options [Hash] Informations required perfrom the task.
|
8
|
+
# options[:app_name] Name of the application that uses Moto Framework.
|
9
|
+
# options[:dir] Subdirectories of MotoApp/tests/ where test should be placed.
|
10
|
+
# options[:base_class] Path and filename of class from which the test will derive.
|
11
|
+
# options[:force] Whether generator should forcibly overwrite previously existing file.
|
12
|
+
def self.run(options)
|
13
|
+
|
14
|
+
# Build list of modules basing on the name of the application and subdirectory provided by the user.
|
15
|
+
# Second module is always 'tests' since it's where they should be kept.
|
16
|
+
modules = [options[:app_name], 'tests'] + options[:dir].split('/')
|
17
|
+
modules.map!(&:camelize)
|
18
|
+
|
19
|
+
# Name of the class in the template
|
20
|
+
class_name = modules.last
|
21
|
+
|
22
|
+
# Evaluate fully qulified name of the class to derive from or, if not specified
|
23
|
+
# use Moto's default one
|
24
|
+
if options[:base_class].nil?
|
25
|
+
base_class_qualified_name = 'Moto::Test'
|
26
|
+
else
|
27
|
+
base_class_qualified_name = "#{options[:app_name]}::Lib::Test::#{options[:base_class].split('/').join('::').camelize}"
|
28
|
+
end
|
29
|
+
|
30
|
+
# Where to put finished template
|
31
|
+
test_file = File.basename(options[:dir]) + '.rb'
|
32
|
+
test_dir = MotoApp::DIR + '/tests/' + options[:dir]
|
33
|
+
test_path = "#{test_dir}/#{test_file}"
|
34
|
+
|
35
|
+
# Create directory
|
36
|
+
FileUtils.mkdir_p(test_dir)
|
37
|
+
|
38
|
+
if !File.exist?(test_path) || options[:force]
|
39
|
+
# Create new file in specified location and add class' template to it
|
40
|
+
File.open(test_path, 'w+') do |file|
|
41
|
+
|
42
|
+
indent = 0
|
43
|
+
|
44
|
+
file << "# FULL_CODE\n"
|
45
|
+
|
46
|
+
if options[:base_class].nil?
|
47
|
+
file << "\n"
|
48
|
+
else
|
49
|
+
file << "require './lib/test/#{options[:base_class]}.rb'\n\n"
|
50
|
+
end
|
51
|
+
|
52
|
+
modules.each do |m|
|
53
|
+
file << (' ' * indent) + "module #{m}\n"
|
54
|
+
indent += 2
|
55
|
+
end
|
56
|
+
|
57
|
+
file << (' ' * indent) + "# Class template genereated by 'moto generate'\n"
|
58
|
+
file << (' ' * indent) + "class #{class_name} < #{base_class_qualified_name}\n\n"
|
59
|
+
indent += 2
|
60
|
+
file << (' ' * indent) + "def run\n"
|
61
|
+
file << (' ' * indent) + "end\n\n"
|
62
|
+
indent -= 2
|
63
|
+
file << (' ' * indent) + "end\n"
|
64
|
+
|
65
|
+
modules.each do
|
66
|
+
indent -= 2
|
67
|
+
file << (' ' * indent) + "end\n"
|
68
|
+
end
|
69
|
+
|
70
|
+
end
|
71
|
+
|
72
|
+
puts 'Result:'
|
73
|
+
puts " File: #{test_path}"
|
74
|
+
puts " Class: #{class_name} < #{base_class_qualified_name}"
|
75
|
+
else
|
76
|
+
raise 'File already exists. Use -f or --force to overwrite existing contents.'
|
77
|
+
end
|
6
78
|
end
|
7
|
-
|
8
79
|
end
|
9
|
-
end
|
80
|
+
end
|
data/lib/empty_listener.rb
CHANGED
@@ -1,17 +1,17 @@
|
|
1
|
-
module Moto
|
2
|
-
module EmptyListener
|
3
|
-
|
4
|
-
def start_run
|
5
|
-
end
|
6
|
-
|
7
|
-
def end_run
|
8
|
-
end
|
9
|
-
|
10
|
-
def start_test(test)
|
11
|
-
end
|
12
|
-
|
13
|
-
def end_test(test)
|
14
|
-
end
|
15
|
-
|
16
|
-
end
|
1
|
+
module Moto
|
2
|
+
module EmptyListener
|
3
|
+
|
4
|
+
def start_run
|
5
|
+
end
|
6
|
+
|
7
|
+
def end_run
|
8
|
+
end
|
9
|
+
|
10
|
+
def start_test(test)
|
11
|
+
end
|
12
|
+
|
13
|
+
def end_test(test)
|
14
|
+
end
|
15
|
+
|
16
|
+
end
|
17
17
|
end
|
data/lib/exceptions/moto.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
|
-
module Moto
|
2
|
-
module Exceptions
|
3
|
-
class MotoException < RuntimeError
|
4
|
-
|
5
|
-
end
|
6
|
-
end
|
1
|
+
module Moto
|
2
|
+
module Exceptions
|
3
|
+
class MotoException < RuntimeError
|
4
|
+
|
5
|
+
end
|
6
|
+
end
|
7
7
|
end
|
@@ -1,7 +1,7 @@
|
|
1
|
-
module Moto
|
2
|
-
module Exceptions
|
3
|
-
class TestForcedFailure < MotoException
|
4
|
-
|
5
|
-
end
|
6
|
-
end
|
1
|
+
module Moto
|
2
|
+
module Exceptions
|
3
|
+
class TestForcedFailure < MotoException
|
4
|
+
|
5
|
+
end
|
6
|
+
end
|
7
7
|
end
|
@@ -1,7 +1,7 @@
|
|
1
|
-
module Moto
|
2
|
-
module Exceptions
|
3
|
-
class TestForcedPassed < MotoException
|
4
|
-
|
5
|
-
end
|
6
|
-
end
|
1
|
+
module Moto
|
2
|
+
module Exceptions
|
3
|
+
class TestForcedPassed < MotoException
|
4
|
+
|
5
|
+
end
|
6
|
+
end
|
7
7
|
end
|
@@ -1,7 +1,7 @@
|
|
1
|
-
module Moto
|
2
|
-
module Exceptions
|
3
|
-
class TestSkipped < MotoException
|
4
|
-
|
5
|
-
end
|
6
|
-
end
|
1
|
+
module Moto
|
2
|
+
module Exceptions
|
3
|
+
class TestSkipped < MotoException
|
4
|
+
|
5
|
+
end
|
6
|
+
end
|
7
7
|
end
|
@@ -1,21 +1,21 @@
|
|
1
|
-
module Moto
|
2
|
-
module ForwardContextMethods
|
3
|
-
|
4
|
-
def client(name)
|
5
|
-
@context.client(name)
|
6
|
-
end
|
7
|
-
|
8
|
-
def logger
|
9
|
-
@context.logger
|
10
|
-
end
|
11
|
-
|
12
|
-
def const(key)
|
13
|
-
@context.const(key)
|
14
|
-
end
|
15
|
-
|
16
|
-
def current_test
|
17
|
-
@context.current_test
|
18
|
-
end
|
19
|
-
|
20
|
-
end
|
1
|
+
module Moto
|
2
|
+
module ForwardContextMethods
|
3
|
+
|
4
|
+
def client(name)
|
5
|
+
@context.client(name)
|
6
|
+
end
|
7
|
+
|
8
|
+
def logger
|
9
|
+
@context.logger
|
10
|
+
end
|
11
|
+
|
12
|
+
def const(key)
|
13
|
+
@context.const(key)
|
14
|
+
end
|
15
|
+
|
16
|
+
def current_test
|
17
|
+
@context.current_test
|
18
|
+
end
|
19
|
+
|
20
|
+
end
|
21
21
|
end
|
data/lib/initializer.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
|
-
module Moto
|
2
|
-
class Initializer
|
3
|
-
def initialize(runner)
|
4
|
-
@runner = runner
|
5
|
-
end
|
6
|
-
end
|
1
|
+
module Moto
|
2
|
+
class Initializer
|
3
|
+
def initialize(runner)
|
4
|
+
@runner = runner
|
5
|
+
end
|
6
|
+
end
|
7
7
|
end
|
data/lib/listeners/base.rb
CHANGED
@@ -1,26 +1,26 @@
|
|
1
|
-
module Moto
|
2
|
-
module Listeners
|
3
|
-
class Base
|
4
|
-
|
5
|
-
def initialize(runner)
|
6
|
-
@runner=runner
|
7
|
-
end
|
8
|
-
|
9
|
-
def start_run
|
10
|
-
# abstract
|
11
|
-
end
|
12
|
-
|
13
|
-
def end_run
|
14
|
-
# abstract
|
15
|
-
end
|
16
|
-
|
17
|
-
def start_test(test)
|
18
|
-
# abstract
|
19
|
-
end
|
20
|
-
|
21
|
-
def end_test(test)
|
22
|
-
# abstract
|
23
|
-
end
|
24
|
-
end
|
25
|
-
end
|
1
|
+
module Moto
|
2
|
+
module Listeners
|
3
|
+
class Base
|
4
|
+
|
5
|
+
def initialize(runner)
|
6
|
+
@runner=runner
|
7
|
+
end
|
8
|
+
|
9
|
+
def start_run
|
10
|
+
# abstract
|
11
|
+
end
|
12
|
+
|
13
|
+
def end_run
|
14
|
+
# abstract
|
15
|
+
end
|
16
|
+
|
17
|
+
def start_test(test)
|
18
|
+
# abstract
|
19
|
+
end
|
20
|
+
|
21
|
+
def end_test(test)
|
22
|
+
# abstract
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
26
|
end
|
data/lib/listeners/console.rb
CHANGED
@@ -1,29 +1,29 @@
|
|
1
|
-
module Moto
|
2
|
-
module Listeners
|
3
|
-
class Console < Base
|
4
|
-
|
5
|
-
def start_run
|
6
|
-
puts "START"
|
7
|
-
end
|
8
|
-
|
9
|
-
def end_run
|
10
|
-
puts ""
|
11
|
-
puts "FINISHED: #{@runner.result.summary[:result]}, duration: #{Time.at(@runner.result.summary[:duration]).utc.strftime("%H:%M:%S")}"
|
12
|
-
puts "Tests executed: #{@runner.result.summary[:cnt_all]}"
|
13
|
-
puts " Passed: #{@runner.result.summary[:cnt_passed]}"
|
14
|
-
puts " Failure: #{@runner.result.summary[:cnt_failure]}"
|
15
|
-
puts " Error: #{@runner.result.summary[:cnt_error]}"
|
16
|
-
puts " Skipped: #{@runner.result.summary[:cnt_skipped]}"
|
17
|
-
end
|
18
|
-
|
19
|
-
def start_test(test)
|
20
|
-
print test.name
|
21
|
-
end
|
22
|
-
|
23
|
-
def end_test(test)
|
24
|
-
puts "\t#{@runner.result[test.name][:result]}"
|
25
|
-
end
|
26
|
-
|
27
|
-
end
|
28
|
-
end
|
1
|
+
module Moto
|
2
|
+
module Listeners
|
3
|
+
class Console < Base
|
4
|
+
|
5
|
+
def start_run
|
6
|
+
puts "START"
|
7
|
+
end
|
8
|
+
|
9
|
+
def end_run
|
10
|
+
puts ""
|
11
|
+
puts "FINISHED: #{@runner.result.summary[:result]}, duration: #{Time.at(@runner.result.summary[:duration]).utc.strftime("%H:%M:%S")}"
|
12
|
+
puts "Tests executed: #{@runner.result.summary[:cnt_all]}"
|
13
|
+
puts " Passed: #{@runner.result.summary[:cnt_passed]}"
|
14
|
+
puts " Failure: #{@runner.result.summary[:cnt_failure]}"
|
15
|
+
puts " Error: #{@runner.result.summary[:cnt_error]}"
|
16
|
+
puts " Skipped: #{@runner.result.summary[:cnt_skipped]}"
|
17
|
+
end
|
18
|
+
|
19
|
+
def start_test(test)
|
20
|
+
print test.name
|
21
|
+
end
|
22
|
+
|
23
|
+
def end_test(test)
|
24
|
+
puts "\t#{@runner.result[test.name][:result]}"
|
25
|
+
end
|
26
|
+
|
27
|
+
end
|
28
|
+
end
|
29
29
|
end
|
@@ -1,63 +1,63 @@
|
|
1
|
-
module Moto
|
2
|
-
module Listeners
|
3
|
-
class ConsoleDots < Base
|
4
|
-
|
5
|
-
def start_run
|
6
|
-
end
|
7
|
-
|
8
|
-
def end_run
|
9
|
-
puts ""
|
10
|
-
puts ""
|
11
|
-
puts "FINISHED: #{@runner.result.summary[:result]}, duration: #{Time.at(@runner.result.summary[:duration]).utc.strftime("%H:%M:%S")}"
|
12
|
-
puts "Tests executed: #{@runner.result.summary[:cnt_all]}"
|
13
|
-
puts " Passed: #{@runner.result.summary[:cnt_passed]}"
|
14
|
-
puts " Failure: #{@runner.result.summary[:cnt_failure]}"
|
15
|
-
puts " Error: #{@runner.result.summary[:cnt_error]}"
|
16
|
-
puts " Skipped: #{@runner.result.summary[:cnt_skipped]}"
|
17
|
-
|
18
|
-
if @runner.result.summary[:cnt_failure] > 0
|
19
|
-
puts ""
|
20
|
-
puts "FAILURES: "
|
21
|
-
@runner.result.summary[:tests_failure].each do |test_name, data|
|
22
|
-
puts test_name
|
23
|
-
puts "\t#{data[:failures].join("\n\t")}"
|
24
|
-
puts ""
|
25
|
-
end
|
26
|
-
end
|
27
|
-
|
28
|
-
if @runner.result.summary[:cnt_error] > 0
|
29
|
-
puts ""
|
30
|
-
puts "ERRORS: "
|
31
|
-
@runner.result.summary[:tests_error].each do |test_name, data|
|
32
|
-
puts test_name
|
33
|
-
puts "\t#{data[:error]}"
|
34
|
-
puts ""
|
35
|
-
end
|
36
|
-
end
|
37
|
-
|
38
|
-
if @runner.result.summary[:cnt_skipped] > 0
|
39
|
-
puts ""
|
40
|
-
puts "SKIPPED: "
|
41
|
-
@runner.result.summary[:tests_skipped].each do |test_name, data|
|
42
|
-
puts test_name
|
43
|
-
puts "\t#{data[:error]}"
|
44
|
-
puts ""
|
45
|
-
end
|
46
|
-
end
|
47
|
-
end
|
48
|
-
|
49
|
-
def start_test(test)
|
50
|
-
end
|
51
|
-
|
52
|
-
def end_test(test)
|
53
|
-
print case @runner.result[test.name][:result]
|
54
|
-
when :passed then "."
|
55
|
-
when :failure then "F"
|
56
|
-
when :error then "E"
|
57
|
-
when :skipped then "S"
|
58
|
-
end
|
59
|
-
end
|
60
|
-
|
61
|
-
end
|
62
|
-
end
|
1
|
+
module Moto
|
2
|
+
module Listeners
|
3
|
+
class ConsoleDots < Base
|
4
|
+
|
5
|
+
def start_run
|
6
|
+
end
|
7
|
+
|
8
|
+
def end_run
|
9
|
+
puts ""
|
10
|
+
puts ""
|
11
|
+
puts "FINISHED: #{@runner.result.summary[:result]}, duration: #{Time.at(@runner.result.summary[:duration]).utc.strftime("%H:%M:%S")}"
|
12
|
+
puts "Tests executed: #{@runner.result.summary[:cnt_all]}"
|
13
|
+
puts " Passed: #{@runner.result.summary[:cnt_passed]}"
|
14
|
+
puts " Failure: #{@runner.result.summary[:cnt_failure]}"
|
15
|
+
puts " Error: #{@runner.result.summary[:cnt_error]}"
|
16
|
+
puts " Skipped: #{@runner.result.summary[:cnt_skipped]}"
|
17
|
+
|
18
|
+
if @runner.result.summary[:cnt_failure] > 0
|
19
|
+
puts ""
|
20
|
+
puts "FAILURES: "
|
21
|
+
@runner.result.summary[:tests_failure].each do |test_name, data|
|
22
|
+
puts test_name
|
23
|
+
puts "\t#{data[:failures].join("\n\t")}"
|
24
|
+
puts ""
|
25
|
+
end
|
26
|
+
end
|
27
|
+
|
28
|
+
if @runner.result.summary[:cnt_error] > 0
|
29
|
+
puts ""
|
30
|
+
puts "ERRORS: "
|
31
|
+
@runner.result.summary[:tests_error].each do |test_name, data|
|
32
|
+
puts test_name
|
33
|
+
puts "\t#{data[:error]}"
|
34
|
+
puts ""
|
35
|
+
end
|
36
|
+
end
|
37
|
+
|
38
|
+
if @runner.result.summary[:cnt_skipped] > 0
|
39
|
+
puts ""
|
40
|
+
puts "SKIPPED: "
|
41
|
+
@runner.result.summary[:tests_skipped].each do |test_name, data|
|
42
|
+
puts test_name
|
43
|
+
puts "\t#{data[:error]}"
|
44
|
+
puts ""
|
45
|
+
end
|
46
|
+
end
|
47
|
+
end
|
48
|
+
|
49
|
+
def start_test(test)
|
50
|
+
end
|
51
|
+
|
52
|
+
def end_test(test)
|
53
|
+
print case @runner.result[test.name][:result]
|
54
|
+
when :passed then "."
|
55
|
+
when :failure then "F"
|
56
|
+
when :error then "E"
|
57
|
+
when :skipped then "S"
|
58
|
+
end
|
59
|
+
end
|
60
|
+
|
61
|
+
end
|
62
|
+
end
|
63
63
|
end
|
data/lib/listeners/junit_xml.rb
CHANGED
@@ -1,37 +1,37 @@
|
|
1
|
-
require 'nokogiri'
|
2
|
-
|
3
|
-
module Moto
|
4
|
-
module Listeners
|
5
|
-
class JunitXml < Base
|
6
|
-
|
7
|
-
def end_run
|
8
|
-
path = @runner.my_config[:output_file]
|
9
|
-
|
10
|
-
builder = Nokogiri::XML::Builder.new { |xml|
|
11
|
-
xml.testsuite(
|
12
|
-
errors: @runner.result.summary[:cnt_error],
|
13
|
-
failures: @runner.result.summary[:cnt_failure],
|
14
|
-
name: "Moto run",
|
15
|
-
tests: @runner.result.summary[:cnt_all],
|
16
|
-
time: @runner.result.summary[:duration],
|
17
|
-
timestamp: Time.at(@runner.result.summary[:started_at])) do
|
18
|
-
@runner.result.all.each do |test_name, data|
|
19
|
-
xml.testcase(name: test_name, time: data[:duration], classname: data[:class].name, moto_result: data[:result]) do
|
20
|
-
if !data[:error].nil?
|
21
|
-
xml.error(message: data[:error].message)
|
22
|
-
elsif data[:failures].count > 0
|
23
|
-
data[:failures].each do |f|
|
24
|
-
xml.failure(message: f)
|
25
|
-
end
|
26
|
-
end
|
27
|
-
end
|
28
|
-
end
|
29
|
-
end
|
30
|
-
}
|
31
|
-
|
32
|
-
File.open(path, 'w') {|f| f.write(builder.to_xml) }
|
33
|
-
end
|
34
|
-
|
35
|
-
end
|
36
|
-
end
|
1
|
+
require 'nokogiri'
|
2
|
+
|
3
|
+
module Moto
|
4
|
+
module Listeners
|
5
|
+
class JunitXml < Base
|
6
|
+
|
7
|
+
def end_run
|
8
|
+
path = @runner.my_config[:output_file]
|
9
|
+
|
10
|
+
builder = Nokogiri::XML::Builder.new { |xml|
|
11
|
+
xml.testsuite(
|
12
|
+
errors: @runner.result.summary[:cnt_error],
|
13
|
+
failures: @runner.result.summary[:cnt_failure],
|
14
|
+
name: "Moto run",
|
15
|
+
tests: @runner.result.summary[:cnt_all],
|
16
|
+
time: @runner.result.summary[:duration],
|
17
|
+
timestamp: Time.at(@runner.result.summary[:started_at])) do
|
18
|
+
@runner.result.all.each do |test_name, data|
|
19
|
+
xml.testcase(name: test_name, time: data[:duration], classname: data[:class].name, moto_result: data[:result]) do
|
20
|
+
if !data[:error].nil?
|
21
|
+
xml.error(message: data[:error].message)
|
22
|
+
elsif data[:failures].count > 0
|
23
|
+
data[:failures].each do |f|
|
24
|
+
xml.failure(message: f)
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
30
|
+
}
|
31
|
+
|
32
|
+
File.open(path, 'w') {|f| f.write(builder.to_xml) }
|
33
|
+
end
|
34
|
+
|
35
|
+
end
|
36
|
+
end
|
37
37
|
end
|
data/lib/parser.rb
CHANGED
@@ -13,9 +13,9 @@ module Moto
|
|
13
13
|
# TODO Generate app / Change the way parsing options goes so it doesnt generate them if they`re not needed
|
14
14
|
case argv[0]
|
15
15
|
when '--version' then puts Moto::VERSION
|
16
|
-
when 'run' then Moto::Cli.run
|
16
|
+
when 'run' then Moto::Cli.run(run_parse(argv))
|
17
17
|
when 'help' then show_help
|
18
|
-
when 'generate' then Moto::AppGenerator.run
|
18
|
+
when 'generate' then Moto::AppGenerator.run(generate_parse(argv))
|
19
19
|
else puts "Command '#{argv[0]}' not recognized. Type help for list of supported commands."
|
20
20
|
end
|
21
21
|
rescue Exception => e
|
@@ -26,7 +26,7 @@ module Moto
|
|
26
26
|
def self.run_parse(argv)
|
27
27
|
|
28
28
|
# TODO: fix this dumb verification of current working directory.
|
29
|
-
|
29
|
+
if !File.exists? "#{MotoApp::DIR}/config/moto.rb"
|
30
30
|
msg = "Config file (config/moto.rb) not present.\n"
|
31
31
|
msg << 'Does current working directory contain Moto application?'
|
32
32
|
raise msg
|
@@ -41,13 +41,13 @@ module Moto
|
|
41
41
|
# TODO Mandatory env var in app config
|
42
42
|
options[:config] = eval(File.read("#{MotoApp::DIR}/config/moto.rb"))
|
43
43
|
options[:environments] = []
|
44
|
-
options[:name] =
|
44
|
+
options[:name] = ''
|
45
45
|
|
46
46
|
# Parse arguments
|
47
47
|
# TODO eval ?
|
48
48
|
# TODO const
|
49
49
|
# TODO reporters should be consts - not strings
|
50
|
-
OptionParser.new do |opts|
|
50
|
+
OptionParser.new do |opts|
|
51
51
|
opts.on('-t', '--tests Tests', Array) { |v| options[:tests ] = v }
|
52
52
|
opts.on('-g', '--tags Tags', Array) { |v| options[:tags ] = v }
|
53
53
|
opts.on('-r', '--reporters Reporters', Array) { |v| options[:reporters] = v }
|
@@ -70,8 +70,8 @@ module Moto
|
|
70
70
|
end
|
71
71
|
|
72
72
|
def self.evaluate_name(tags, tests)
|
73
|
-
tags ||=
|
74
|
-
tests ||=
|
73
|
+
tags ||= ''
|
74
|
+
tests ||= ''
|
75
75
|
if !tags.empty? && !tests.empty?
|
76
76
|
return "#{tags.count} tags + #{tests.count} tests"
|
77
77
|
elsif tags.empty?
|
@@ -80,22 +80,53 @@ module Moto
|
|
80
80
|
return tags.count == 1 ? "Tag: #{tags.first}" : "#{tags.count} tags"
|
81
81
|
end
|
82
82
|
end
|
83
|
-
|
83
|
+
|
84
|
+
# Parses attributes passed to the application when run by 'moto generate'
|
84
85
|
def self.generate_parse(argv)
|
85
86
|
options = {}
|
86
|
-
|
87
|
+
|
88
|
+
OptionParser.new do |opts|
|
89
|
+
opts.on('-t', '--test Test') { |v| options[:dir ] = v }
|
90
|
+
opts.on('-a', '--appname AppName') { |v| options[:app_name ] = v }
|
91
|
+
opts.on('-b', '--baseclass BaseClass') { |v| options[:base_class] = v }
|
92
|
+
opts.on('-f', '--force') { options[:force ] = true }
|
93
|
+
end.parse!
|
94
|
+
|
95
|
+
options[:dir] = options[:dir].underscore
|
96
|
+
|
97
|
+
if options[:app_name].nil?
|
98
|
+
options[:app_name] = 'MotoApp'
|
99
|
+
end
|
100
|
+
|
101
|
+
return options
|
87
102
|
end
|
88
103
|
|
89
104
|
def self.show_help
|
90
105
|
puts """
|
91
106
|
Moto (#{Moto::VERSION}) CLI Help:
|
92
107
|
moto --version Display current version
|
108
|
+
|
93
109
|
moto run:
|
94
|
-
-t, --tests
|
95
|
-
|
110
|
+
-t, --tests = Tests to be executed.
|
111
|
+
For eg. Tests\Failure\Failure.rb should be passed as Tests::Failure
|
112
|
+
-r, --reporter = Reporters to be used.
|
113
|
+
Defaults are Moto::Listeners::ConsoleDots, Moto::Listeners::JunitXml
|
96
114
|
-e, --environment etc etc
|
115
|
+
|
97
116
|
moto generate:
|
98
|
-
|
117
|
+
-t, --test = Path and name of the test to be created.
|
118
|
+
Examples:
|
119
|
+
-ttest_name will create MotoApp/tests/test_name/test_name.rb
|
120
|
+
-tdir/test_name will create MotoApp/tests/dir/test_name/test_name.rb
|
121
|
+
-a, --appname = Name of the application. Will be also used as topmost module in test file.
|
122
|
+
Default: MotoApp
|
123
|
+
-b, --baseclass = File (WITHOUT EXTENSION) with base class from which test will derive. Assumes one class per file.
|
124
|
+
Examples:
|
125
|
+
-btest_base will use the file in MotoApp/lib/test/test_base.rb
|
126
|
+
-bsubdir/test_base will use the file in MotoApp/lib/test/subdir/test_base.rb
|
127
|
+
By default class will derive from Moto::Test
|
128
|
+
-f, --force = Forces generator to overwrite previously existing class file in specified location.
|
129
|
+
You have been warned.
|
99
130
|
"""
|
100
131
|
end
|
101
132
|
|
data/lib/result.rb
CHANGED
@@ -1,84 +1,84 @@
|
|
1
|
-
module Moto
|
2
|
-
class Result
|
3
|
-
|
4
|
-
PENDING = :pending # -2
|
5
|
-
RUNNING = :running # -1
|
6
|
-
PASSED = :passed # 0
|
7
|
-
FAILURE = :failure # 1
|
8
|
-
ERROR = :error # 2
|
9
|
-
SKIPPED = :skipped # 3
|
10
|
-
|
11
|
-
attr_reader :summary
|
12
|
-
|
13
|
-
def [](key)
|
14
|
-
@results[key]
|
15
|
-
end
|
16
|
-
|
17
|
-
def all
|
18
|
-
@results
|
19
|
-
end
|
20
|
-
|
21
|
-
def initialize(runner)
|
22
|
-
@runner = runner
|
23
|
-
@results = {}
|
24
|
-
@summary = {}
|
25
|
-
end
|
26
|
-
|
27
|
-
def start_run
|
28
|
-
# start timer
|
29
|
-
@summary[:started_at] = Time.now.to_f
|
30
|
-
end
|
31
|
-
|
32
|
-
def end_run
|
33
|
-
# info about duration and overall execution result
|
34
|
-
@summary[:finished_at] = Time.now.to_f
|
35
|
-
@summary[:duration] = @summary[:finished_at] - @summary[:started_at]
|
36
|
-
@summary[:result] = PASSED
|
37
|
-
@summary[:result] = FAILURE unless @results.values.select{ |v| v[:failures].count > 0 }.empty?
|
38
|
-
@summary[:result] = ERROR unless @results.values.select{ |v| v[:result] == ERROR }.empty?
|
39
|
-
@summary[:cnt_all] = @results.count
|
40
|
-
@summary[:tests_passed] = @results.select{ |k,v| v[:result] == PASSED }
|
41
|
-
@summary[:tests_failure] = @results.select{ |k,v| v[:result] == FAILURE }
|
42
|
-
@summary[:tests_error] = @results.select{ |k,v| v[:result] == ERROR }
|
43
|
-
@summary[:tests_skipped] = @results.select{ |k,v| v[:result] == SKIPPED }
|
44
|
-
@summary[:cnt_passed] = @summary[:tests_passed].count
|
45
|
-
@summary[:cnt_failure] = @summary[:tests_failure].count
|
46
|
-
@summary[:cnt_error] = @summary[:tests_error].count
|
47
|
-
@summary[:cnt_skipped] = @summary[:tests_skipped].count
|
48
|
-
end
|
49
|
-
|
50
|
-
def start_test(test)
|
51
|
-
@results[test.name] = { class: test.class, result: RUNNING, env: test.env, params: test.params, name: test.name, error: nil, failures: [], started_at: Time.now.to_f }
|
52
|
-
end
|
53
|
-
|
54
|
-
def end_test(test)
|
55
|
-
# calculate result basing on errors/failures
|
56
|
-
@results[test.name][:finished_at] = Time.now.to_f
|
57
|
-
test.result = PASSED
|
58
|
-
test.result = FAILURE unless @results[test.name][:failures].empty?
|
59
|
-
unless @results[test.name][:error].nil?
|
60
|
-
if @results[test.name][:error].is_a? Moto::Exceptions::TestSkipped
|
61
|
-
test.result = SKIPPED
|
62
|
-
elsif @results[test.name][:error].is_a? Moto::Exceptions::TestForcedPassed
|
63
|
-
test.result = PASSED
|
64
|
-
elsif @results[test.name][:error].is_a? Moto::Exceptions::TestForcedFailure
|
65
|
-
add_failure(test, @results[test.name][:error].message)
|
66
|
-
test.result = FAILURE
|
67
|
-
else
|
68
|
-
test.result = ERROR
|
69
|
-
end
|
70
|
-
end
|
71
|
-
@results[test.name][:duration] = @results[test.name][:finished_at] - @results[test.name][:started_at]
|
72
|
-
@results[test.name][:result] = test.result
|
73
|
-
end
|
74
|
-
|
75
|
-
def add_failure(test, msg)
|
76
|
-
@results[test.name][:failures] << msg
|
77
|
-
end
|
78
|
-
|
79
|
-
def add_error(test, e)
|
80
|
-
@results[test.name][:error] = e
|
81
|
-
end
|
82
|
-
|
83
|
-
end
|
1
|
+
module Moto
|
2
|
+
class Result
|
3
|
+
|
4
|
+
PENDING = :pending # -2
|
5
|
+
RUNNING = :running # -1
|
6
|
+
PASSED = :passed # 0
|
7
|
+
FAILURE = :failure # 1
|
8
|
+
ERROR = :error # 2
|
9
|
+
SKIPPED = :skipped # 3
|
10
|
+
|
11
|
+
attr_reader :summary
|
12
|
+
|
13
|
+
def [](key)
|
14
|
+
@results[key]
|
15
|
+
end
|
16
|
+
|
17
|
+
def all
|
18
|
+
@results
|
19
|
+
end
|
20
|
+
|
21
|
+
def initialize(runner)
|
22
|
+
@runner = runner
|
23
|
+
@results = {}
|
24
|
+
@summary = {}
|
25
|
+
end
|
26
|
+
|
27
|
+
def start_run
|
28
|
+
# start timer
|
29
|
+
@summary[:started_at] = Time.now.to_f
|
30
|
+
end
|
31
|
+
|
32
|
+
def end_run
|
33
|
+
# info about duration and overall execution result
|
34
|
+
@summary[:finished_at] = Time.now.to_f
|
35
|
+
@summary[:duration] = @summary[:finished_at] - @summary[:started_at]
|
36
|
+
@summary[:result] = PASSED
|
37
|
+
@summary[:result] = FAILURE unless @results.values.select{ |v| v[:failures].count > 0 }.empty?
|
38
|
+
@summary[:result] = ERROR unless @results.values.select{ |v| v[:result] == ERROR }.empty?
|
39
|
+
@summary[:cnt_all] = @results.count
|
40
|
+
@summary[:tests_passed] = @results.select{ |k,v| v[:result] == PASSED }
|
41
|
+
@summary[:tests_failure] = @results.select{ |k,v| v[:result] == FAILURE }
|
42
|
+
@summary[:tests_error] = @results.select{ |k,v| v[:result] == ERROR }
|
43
|
+
@summary[:tests_skipped] = @results.select{ |k,v| v[:result] == SKIPPED }
|
44
|
+
@summary[:cnt_passed] = @summary[:tests_passed].count
|
45
|
+
@summary[:cnt_failure] = @summary[:tests_failure].count
|
46
|
+
@summary[:cnt_error] = @summary[:tests_error].count
|
47
|
+
@summary[:cnt_skipped] = @summary[:tests_skipped].count
|
48
|
+
end
|
49
|
+
|
50
|
+
def start_test(test)
|
51
|
+
@results[test.name] = { class: test.class, result: RUNNING, env: test.env, params: test.params, name: test.name, error: nil, failures: [], started_at: Time.now.to_f }
|
52
|
+
end
|
53
|
+
|
54
|
+
def end_test(test)
|
55
|
+
# calculate result basing on errors/failures
|
56
|
+
@results[test.name][:finished_at] = Time.now.to_f
|
57
|
+
test.result = PASSED
|
58
|
+
test.result = FAILURE unless @results[test.name][:failures].empty?
|
59
|
+
unless @results[test.name][:error].nil?
|
60
|
+
if @results[test.name][:error].is_a? Moto::Exceptions::TestSkipped
|
61
|
+
test.result = SKIPPED
|
62
|
+
elsif @results[test.name][:error].is_a? Moto::Exceptions::TestForcedPassed
|
63
|
+
test.result = PASSED
|
64
|
+
elsif @results[test.name][:error].is_a? Moto::Exceptions::TestForcedFailure
|
65
|
+
add_failure(test, @results[test.name][:error].message)
|
66
|
+
test.result = FAILURE
|
67
|
+
else
|
68
|
+
test.result = ERROR
|
69
|
+
end
|
70
|
+
end
|
71
|
+
@results[test.name][:duration] = @results[test.name][:finished_at] - @results[test.name][:started_at]
|
72
|
+
@results[test.name][:result] = test.result
|
73
|
+
end
|
74
|
+
|
75
|
+
def add_failure(test, msg)
|
76
|
+
@results[test.name][:failures] << msg
|
77
|
+
end
|
78
|
+
|
79
|
+
def add_error(test, e)
|
80
|
+
@results[test.name][:error] = e
|
81
|
+
end
|
82
|
+
|
83
|
+
end
|
84
84
|
end
|
data/lib/runner_logging.rb
CHANGED
@@ -1,27 +1,27 @@
|
|
1
|
-
module Moto
|
2
|
-
module RunnerLogging
|
3
|
-
|
4
|
-
|
5
|
-
# TODO: merge it somehow with TestLogging. Parametrize logger object?
|
6
|
-
def self.included(cls)
|
7
|
-
def cls.method_added(name)
|
8
|
-
excluded_methods = Moto::EmptyListener.instance_methods(false)
|
9
|
-
excluded_methods << :new
|
10
|
-
excluded_methods << :initialize
|
11
|
-
# TODO: configure more excluded classes/methods
|
12
|
-
return if @added
|
13
|
-
@added = true # protect from recursion
|
14
|
-
original_method = "original_#{name}"
|
15
|
-
alias_method original_method, name
|
16
|
-
define_method(name) do |*args|
|
17
|
-
@context.runner.logger.debug("#{self.class.name}::#{__callee__} ENTER >>> #{args}") unless excluded_methods.include? name
|
18
|
-
result = send original_method, *args
|
19
|
-
@context.runner.logger.debug("#{self.class.name}::#{__callee__} LEAVE <<< #{result} ") unless excluded_methods.include? name
|
20
|
-
result
|
21
|
-
end
|
22
|
-
@added = false
|
23
|
-
end
|
24
|
-
|
25
|
-
end
|
26
|
-
end
|
1
|
+
module Moto
|
2
|
+
module RunnerLogging
|
3
|
+
|
4
|
+
|
5
|
+
# TODO: merge it somehow with TestLogging. Parametrize logger object?
|
6
|
+
def self.included(cls)
|
7
|
+
def cls.method_added(name)
|
8
|
+
excluded_methods = Moto::EmptyListener.instance_methods(false)
|
9
|
+
excluded_methods << :new
|
10
|
+
excluded_methods << :initialize
|
11
|
+
# TODO: configure more excluded classes/methods
|
12
|
+
return if @added
|
13
|
+
@added = true # protect from recursion
|
14
|
+
original_method = "original_#{name}"
|
15
|
+
alias_method original_method, name
|
16
|
+
define_method(name) do |*args|
|
17
|
+
@context.runner.logger.debug("#{self.class.name}::#{__callee__} ENTER >>> #{args}") unless excluded_methods.include? name
|
18
|
+
result = send original_method, *args
|
19
|
+
@context.runner.logger.debug("#{self.class.name}::#{__callee__} LEAVE <<< #{result} ") unless excluded_methods.include? name
|
20
|
+
result
|
21
|
+
end
|
22
|
+
@added = false
|
23
|
+
end
|
24
|
+
|
25
|
+
end
|
26
|
+
end
|
27
27
|
end
|
data/lib/test_logging.rb
CHANGED
@@ -1,49 +1,49 @@
|
|
1
|
-
module Moto
|
2
|
-
module TestLogging
|
3
|
-
|
4
|
-
@@ignore_logging = []
|
5
|
-
|
6
|
-
def self.included(cls)
|
7
|
-
|
8
|
-
def cls.ignore_logging(method)
|
9
|
-
full_name = "#{self.name}::#{method}"
|
10
|
-
@@ignore_logging << full_name
|
11
|
-
end
|
12
|
-
|
13
|
-
def cls.method_added(name)
|
14
|
-
|
15
|
-
Moto::EmptyListener.instance_methods(false).each do |m|
|
16
|
-
full_name = "#{self.name}::#{m}"
|
17
|
-
@@ignore_logging << full_name unless @@ignore_logging.include? full_name
|
18
|
-
end
|
19
|
-
@@ignore_logging << "#{self.name}::new"
|
20
|
-
@@ignore_logging << "#{self.name}::initialize"
|
21
|
-
|
22
|
-
return if @added
|
23
|
-
@added = true # protect from recursion
|
24
|
-
original_method = "original_#{name}"
|
25
|
-
alias_method original_method, name
|
26
|
-
define_method(name) do |*args|
|
27
|
-
full_name = "#{self.class.name}::#{__callee__}"
|
28
|
-
# TODO: use self.class.ancestors to figure out if ancestor::__callee__ is not in @@ignore_logging
|
29
|
-
skip_logging = @@ignore_logging.include? full_name
|
30
|
-
unless skip_logging
|
31
|
-
self.class.ancestors.each do |a|
|
32
|
-
ancestor_name = "#{a.name}::#{__callee__}"
|
33
|
-
if @@ignore_logging.include? ancestor_name
|
34
|
-
skip_logging = true
|
35
|
-
break
|
36
|
-
end
|
37
|
-
end
|
38
|
-
end
|
39
|
-
@context.current_test.logger.debug("ENTER >>> #{self.class.name}::#{__callee__}(#{args})") unless skip_logging
|
40
|
-
result = send original_method, *args
|
41
|
-
@context.current_test.logger.debug("LEAVE <<< #{self.class.name}::#{__callee__} => #{result} ") unless skip_logging
|
42
|
-
result
|
43
|
-
end
|
44
|
-
@added = false
|
45
|
-
end
|
46
|
-
end
|
47
|
-
|
48
|
-
end
|
1
|
+
module Moto
|
2
|
+
module TestLogging
|
3
|
+
|
4
|
+
@@ignore_logging = []
|
5
|
+
|
6
|
+
def self.included(cls)
|
7
|
+
|
8
|
+
def cls.ignore_logging(method)
|
9
|
+
full_name = "#{self.name}::#{method}"
|
10
|
+
@@ignore_logging << full_name
|
11
|
+
end
|
12
|
+
|
13
|
+
def cls.method_added(name)
|
14
|
+
|
15
|
+
Moto::EmptyListener.instance_methods(false).each do |m|
|
16
|
+
full_name = "#{self.name}::#{m}"
|
17
|
+
@@ignore_logging << full_name unless @@ignore_logging.include? full_name
|
18
|
+
end
|
19
|
+
@@ignore_logging << "#{self.name}::new"
|
20
|
+
@@ignore_logging << "#{self.name}::initialize"
|
21
|
+
|
22
|
+
return if @added
|
23
|
+
@added = true # protect from recursion
|
24
|
+
original_method = "original_#{name}"
|
25
|
+
alias_method original_method, name
|
26
|
+
define_method(name) do |*args|
|
27
|
+
full_name = "#{self.class.name}::#{__callee__}"
|
28
|
+
# TODO: use self.class.ancestors to figure out if ancestor::__callee__ is not in @@ignore_logging
|
29
|
+
skip_logging = @@ignore_logging.include? full_name
|
30
|
+
unless skip_logging
|
31
|
+
self.class.ancestors.each do |a|
|
32
|
+
ancestor_name = "#{a.name}::#{__callee__}"
|
33
|
+
if @@ignore_logging.include? ancestor_name
|
34
|
+
skip_logging = true
|
35
|
+
break
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
39
|
+
@context.current_test.logger.debug("ENTER >>> #{self.class.name}::#{__callee__}(#{args})") unless skip_logging
|
40
|
+
result = send original_method, *args
|
41
|
+
@context.current_test.logger.debug("LEAVE <<< #{self.class.name}::#{__callee__} => #{result} ") unless skip_logging
|
42
|
+
result
|
43
|
+
end
|
44
|
+
@added = false
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
end
|
49
49
|
end
|
data/lib/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: moto
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.25
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bartek Wilczek
|
@@ -10,62 +10,62 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2016-02-
|
13
|
+
date: 2016-02-29 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: activesupport
|
17
17
|
requirement: !ruby/object:Gem::Requirement
|
18
18
|
requirements:
|
19
|
-
- -
|
19
|
+
- - '>='
|
20
20
|
- !ruby/object:Gem::Version
|
21
21
|
version: '3.2'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
25
25
|
requirements:
|
26
|
-
- -
|
26
|
+
- - '>='
|
27
27
|
- !ruby/object:Gem::Version
|
28
28
|
version: '3.2'
|
29
29
|
- !ruby/object:Gem::Dependency
|
30
30
|
name: nokogiri
|
31
31
|
requirement: !ruby/object:Gem::Requirement
|
32
32
|
requirements:
|
33
|
-
- -
|
33
|
+
- - '>='
|
34
34
|
- !ruby/object:Gem::Version
|
35
35
|
version: '0'
|
36
36
|
type: :runtime
|
37
37
|
prerelease: false
|
38
38
|
version_requirements: !ruby/object:Gem::Requirement
|
39
39
|
requirements:
|
40
|
-
- -
|
40
|
+
- - '>='
|
41
41
|
- !ruby/object:Gem::Version
|
42
42
|
version: '0'
|
43
43
|
- !ruby/object:Gem::Dependency
|
44
44
|
name: rest-client
|
45
45
|
requirement: !ruby/object:Gem::Requirement
|
46
46
|
requirements:
|
47
|
-
- -
|
47
|
+
- - '>='
|
48
48
|
- !ruby/object:Gem::Version
|
49
49
|
version: '0'
|
50
50
|
type: :runtime
|
51
51
|
prerelease: false
|
52
52
|
version_requirements: !ruby/object:Gem::Requirement
|
53
53
|
requirements:
|
54
|
-
- -
|
54
|
+
- - '>='
|
55
55
|
- !ruby/object:Gem::Version
|
56
56
|
version: '0'
|
57
57
|
- !ruby/object:Gem::Dependency
|
58
58
|
name: sys-uname
|
59
59
|
requirement: !ruby/object:Gem::Requirement
|
60
60
|
requirements:
|
61
|
-
- -
|
61
|
+
- - '>='
|
62
62
|
- !ruby/object:Gem::Version
|
63
63
|
version: '0'
|
64
64
|
type: :runtime
|
65
65
|
prerelease: false
|
66
66
|
version_requirements: !ruby/object:Gem::Requirement
|
67
67
|
requirements:
|
68
|
-
- -
|
68
|
+
- - '>='
|
69
69
|
- !ruby/object:Gem::Version
|
70
70
|
version: '0'
|
71
71
|
description: This is a development version of a rails philosophy inspired framework
|
@@ -81,24 +81,12 @@ executables:
|
|
81
81
|
extensions: []
|
82
82
|
extra_rdoc_files: []
|
83
83
|
files:
|
84
|
-
- bin/moto
|
85
84
|
- lib/app_generator.rb
|
86
85
|
- lib/assert.rb
|
87
86
|
- lib/cli.rb
|
88
|
-
- lib/clients/base.rb
|
89
|
-
- lib/clients/website.rb
|
90
87
|
- lib/empty_listener.rb
|
91
|
-
- lib/exceptions/moto.rb
|
92
|
-
- lib/exceptions/test_forced_failure.rb
|
93
|
-
- lib/exceptions/test_forced_passed.rb
|
94
|
-
- lib/exceptions/test_skipped.rb
|
95
88
|
- lib/forward_context_methods.rb
|
96
89
|
- lib/initializer.rb
|
97
|
-
- lib/listeners/base.rb
|
98
|
-
- lib/listeners/console.rb
|
99
|
-
- lib/listeners/console_dots.rb
|
100
|
-
- lib/listeners/junit_xml.rb
|
101
|
-
- lib/listeners/webui.rb
|
102
90
|
- lib/page.rb
|
103
91
|
- lib/parser.rb
|
104
92
|
- lib/result.rb
|
@@ -110,6 +98,18 @@ files:
|
|
110
98
|
- lib/thread_context.rb
|
111
99
|
- lib/thread_pool.rb
|
112
100
|
- lib/version.rb
|
101
|
+
- lib/clients/base.rb
|
102
|
+
- lib/clients/website.rb
|
103
|
+
- lib/exceptions/moto.rb
|
104
|
+
- lib/exceptions/test_forced_failure.rb
|
105
|
+
- lib/exceptions/test_forced_passed.rb
|
106
|
+
- lib/exceptions/test_skipped.rb
|
107
|
+
- lib/listeners/base.rb
|
108
|
+
- lib/listeners/console.rb
|
109
|
+
- lib/listeners/console_dots.rb
|
110
|
+
- lib/listeners/junit_xml.rb
|
111
|
+
- lib/listeners/webui.rb
|
112
|
+
- bin/moto
|
113
113
|
homepage: https://github.com/bwilczek/moto
|
114
114
|
licenses:
|
115
115
|
- MIT
|
@@ -120,17 +120,17 @@ require_paths:
|
|
120
120
|
- lib
|
121
121
|
required_ruby_version: !ruby/object:Gem::Requirement
|
122
122
|
requirements:
|
123
|
-
- -
|
123
|
+
- - ~>
|
124
124
|
- !ruby/object:Gem::Version
|
125
125
|
version: '2.0'
|
126
126
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
127
127
|
requirements:
|
128
|
-
- -
|
128
|
+
- - '>='
|
129
129
|
- !ruby/object:Gem::Version
|
130
130
|
version: '0'
|
131
131
|
requirements: []
|
132
132
|
rubyforge_project:
|
133
|
-
rubygems_version: 2.
|
133
|
+
rubygems_version: 2.0.14.1
|
134
134
|
signing_key:
|
135
135
|
specification_version: 4
|
136
136
|
summary: Moto - yet another web testing framework
|