lucid 0.3.0 → 0.3.3
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/.gitignore +9 -9
- data/.travis.yml +3 -2
- data/Gemfile +4 -6
- data/HISTORY.md +7 -2
- data/README.md +10 -8
- data/Rakefile +10 -5
- data/bin/lucid +1 -3
- data/lib/lucid/cli/configuration.rb +1 -1
- data/lib/lucid/factory.rb +26 -26
- data/lib/lucid/platform.rb +1 -1
- data/lib/lucid/runtime/orchestrator.rb +1 -1
- data/lucid.gemspec +42 -32
- data/spec/lucid/app_spec.rb +7 -24
- data/spec/lucid/factory_spec.rb +3 -3
- data/spec/spec_helper.rb +9 -6
- metadata +36 -64
- data/lib/autotest/discover.rb +0 -11
- data/lib/autotest/lucid.rb +0 -6
- data/lib/autotest/lucid_mixin.rb +0 -134
- data/lib/autotest/lucid_rails.rb +0 -6
- data/lib/autotest/lucid_rails_rspec.rb +0 -6
- data/lib/autotest/lucid_rails_rspec2.rb +0 -6
- data/lib/autotest/lucid_rspec.rb +0 -6
- data/lib/autotest/lucid_rspec2.rb +0 -6
- data/lib/lucid/rspec/allow_doubles.rb +0 -20
- data/lib/lucid/rspec/disallow_options.rb +0 -27
- data/lib/lucid/wire_support/configuration.rb +0 -38
- data/lib/lucid/wire_support/connection.rb +0 -61
- data/lib/lucid/wire_support/request_handler.rb +0 -32
- data/lib/lucid/wire_support/wire_exception.rb +0 -32
- data/lib/lucid/wire_support/wire_language.rb +0 -54
- data/lib/lucid/wire_support/wire_packet.rb +0 -34
- data/lib/lucid/wire_support/wire_protocol.rb +0 -43
- data/lib/lucid/wire_support/wire_protocol/requests.rb +0 -125
- data/lib/lucid/wire_support/wire_step_definition.rb +0 -26
metadata
CHANGED
@@ -1,71 +1,57 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lucid
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jeff Nyman
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2014-02-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
|
-
name:
|
14
|
+
name: bundler
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
18
|
-
- !ruby/object:Gem::Version
|
19
|
-
version: 0.18.1
|
20
|
-
type: :runtime
|
21
|
-
prerelease: false
|
22
|
-
version_requirements: !ruby/object:Gem::Requirement
|
23
|
-
requirements:
|
24
|
-
- - '>='
|
25
|
-
- !ruby/object:Gem::Version
|
26
|
-
version: 0.18.1
|
27
|
-
- !ruby/object:Gem::Dependency
|
28
|
-
name: builder
|
29
|
-
requirement: !ruby/object:Gem::Requirement
|
30
|
-
requirements:
|
31
|
-
- - '>='
|
17
|
+
- - ~>
|
32
18
|
- !ruby/object:Gem::Version
|
33
|
-
version:
|
34
|
-
type: :
|
19
|
+
version: '1.5'
|
20
|
+
type: :development
|
35
21
|
prerelease: false
|
36
22
|
version_requirements: !ruby/object:Gem::Requirement
|
37
23
|
requirements:
|
38
|
-
- -
|
24
|
+
- - ~>
|
39
25
|
- !ruby/object:Gem::Version
|
40
|
-
version:
|
26
|
+
version: '1.5'
|
41
27
|
- !ruby/object:Gem::Dependency
|
42
|
-
name:
|
28
|
+
name: rake
|
43
29
|
requirement: !ruby/object:Gem::Requirement
|
44
30
|
requirements:
|
45
31
|
- - '>='
|
46
32
|
- !ruby/object:Gem::Version
|
47
|
-
version:
|
48
|
-
type: :
|
33
|
+
version: '0'
|
34
|
+
type: :development
|
49
35
|
prerelease: false
|
50
36
|
version_requirements: !ruby/object:Gem::Requirement
|
51
37
|
requirements:
|
52
38
|
- - '>='
|
53
39
|
- !ruby/object:Gem::Version
|
54
|
-
version:
|
40
|
+
version: '0'
|
55
41
|
- !ruby/object:Gem::Dependency
|
56
|
-
name:
|
42
|
+
name: builder
|
57
43
|
requirement: !ruby/object:Gem::Requirement
|
58
44
|
requirements:
|
59
45
|
- - '>='
|
60
46
|
- !ruby/object:Gem::Version
|
61
|
-
version: 2.
|
47
|
+
version: 3.2.2
|
62
48
|
type: :runtime
|
63
49
|
prerelease: false
|
64
50
|
version_requirements: !ruby/object:Gem::Requirement
|
65
51
|
requirements:
|
66
52
|
- - '>='
|
67
53
|
- !ruby/object:Gem::Version
|
68
|
-
version: 2.
|
54
|
+
version: 3.2.2
|
69
55
|
- !ruby/object:Gem::Dependency
|
70
56
|
name: multi_json
|
71
57
|
requirement: !ruby/object:Gem::Requirement
|
@@ -87,34 +73,38 @@ dependencies:
|
|
87
73
|
- !ruby/object:Gem::Version
|
88
74
|
version: '2.0'
|
89
75
|
- !ruby/object:Gem::Dependency
|
90
|
-
name:
|
76
|
+
name: gherkin
|
91
77
|
requirement: !ruby/object:Gem::Requirement
|
92
78
|
requirements:
|
93
79
|
- - '>='
|
94
80
|
- !ruby/object:Gem::Version
|
95
|
-
version:
|
96
|
-
type: :
|
81
|
+
version: 2.12.0
|
82
|
+
type: :runtime
|
97
83
|
prerelease: false
|
98
84
|
version_requirements: !ruby/object:Gem::Requirement
|
99
85
|
requirements:
|
100
86
|
- - '>='
|
101
87
|
- !ruby/object:Gem::Version
|
102
|
-
version:
|
88
|
+
version: 2.12.0
|
103
89
|
- !ruby/object:Gem::Dependency
|
104
|
-
name:
|
90
|
+
name: rspec
|
105
91
|
requirement: !ruby/object:Gem::Requirement
|
106
92
|
requirements:
|
107
93
|
- - '>='
|
108
94
|
- !ruby/object:Gem::Version
|
109
|
-
version:
|
110
|
-
type: :
|
95
|
+
version: '2.14'
|
96
|
+
type: :runtime
|
111
97
|
prerelease: false
|
112
98
|
version_requirements: !ruby/object:Gem::Requirement
|
113
99
|
requirements:
|
114
100
|
- - '>='
|
115
101
|
- !ruby/object:Gem::Version
|
116
|
-
version:
|
117
|
-
description:
|
102
|
+
version: '2.14'
|
103
|
+
description: |2
|
104
|
+
Lucid is a test framework that is designed to treat testing as a
|
105
|
+
design activity by allowing requirements to be defined as tests.
|
106
|
+
Those tests can then be executed via an automation layer. This is
|
107
|
+
the basis of creating executable specifications.
|
118
108
|
email: jeffnyman@gmail.com
|
119
109
|
executables:
|
120
110
|
- lucid
|
@@ -131,14 +121,6 @@ files:
|
|
131
121
|
- Rakefile
|
132
122
|
- bin/lucid
|
133
123
|
- bin/lucid-gen
|
134
|
-
- lib/autotest/discover.rb
|
135
|
-
- lib/autotest/lucid.rb
|
136
|
-
- lib/autotest/lucid_mixin.rb
|
137
|
-
- lib/autotest/lucid_rails.rb
|
138
|
-
- lib/autotest/lucid_rails_rspec.rb
|
139
|
-
- lib/autotest/lucid_rails_rspec2.rb
|
140
|
-
- lib/autotest/lucid_rspec.rb
|
141
|
-
- lib/autotest/lucid_rspec2.rb
|
142
124
|
- lib/lucid.rb
|
143
125
|
- lib/lucid/ast.rb
|
144
126
|
- lib/lucid/ast/background.rb
|
@@ -216,8 +198,6 @@ files:
|
|
216
198
|
- lib/lucid/interface_rb/regexp_argument_matcher.rb
|
217
199
|
- lib/lucid/load_path.rb
|
218
200
|
- lib/lucid/platform.rb
|
219
|
-
- lib/lucid/rspec/allow_doubles.rb
|
220
|
-
- lib/lucid/rspec/disallow_options.rb
|
221
201
|
- lib/lucid/runtime.rb
|
222
202
|
- lib/lucid/runtime/facade.rb
|
223
203
|
- lib/lucid/runtime/interface_io.rb
|
@@ -238,15 +218,6 @@ files:
|
|
238
218
|
- lib/lucid/tdl_builder.rb
|
239
219
|
- lib/lucid/term/ansicolor.rb
|
240
220
|
- lib/lucid/unit.rb
|
241
|
-
- lib/lucid/wire_support/configuration.rb
|
242
|
-
- lib/lucid/wire_support/connection.rb
|
243
|
-
- lib/lucid/wire_support/request_handler.rb
|
244
|
-
- lib/lucid/wire_support/wire_exception.rb
|
245
|
-
- lib/lucid/wire_support/wire_language.rb
|
246
|
-
- lib/lucid/wire_support/wire_packet.rb
|
247
|
-
- lib/lucid/wire_support/wire_protocol.rb
|
248
|
-
- lib/lucid/wire_support/wire_protocol/requests.rb
|
249
|
-
- lib/lucid/wire_support/wire_step_definition.rb
|
250
221
|
- lucid.gemspec
|
251
222
|
- spec/lucid/ansicolor_spec.rb
|
252
223
|
- spec/lucid/app_spec.rb
|
@@ -289,10 +260,11 @@ licenses:
|
|
289
260
|
- MIT
|
290
261
|
metadata: {}
|
291
262
|
post_install_message: "\n(::) (::) (::) (::) (::) (::) (::) (::) (::) (::) (::) (::)\n\n
|
292
|
-
\
|
293
|
-
|
294
|
-
|
295
|
-
|
263
|
+
\ Lucid 0.3.3 has been installed.\n\n Run the following command to get help:\n
|
264
|
+
\ lucid --help\n\n Information on Lucid can be found under the 'lucid'\n category
|
265
|
+
at:\n http://testerstories.com/category/lucid/\n\n(::) (::) (::) (::) (::) (::)
|
266
|
+
(::) (::) (::) (::) (::) (::)\n "
|
267
|
+
rdoc_options: []
|
296
268
|
require_paths:
|
297
269
|
- lib
|
298
270
|
required_ruby_version: !ruby/object:Gem::Requirement
|
@@ -304,13 +276,13 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
304
276
|
requirements:
|
305
277
|
- - '>='
|
306
278
|
- !ruby/object:Gem::Version
|
307
|
-
version:
|
279
|
+
version: 1.6.1
|
308
280
|
requirements: []
|
309
281
|
rubyforge_project:
|
310
|
-
rubygems_version: 2.0.
|
282
|
+
rubygems_version: 2.0.14
|
311
283
|
signing_key:
|
312
284
|
specification_version: 4
|
313
|
-
summary:
|
285
|
+
summary: Test Description Language Specification and Execution Engine
|
314
286
|
test_files:
|
315
287
|
- spec/lucid/ansicolor_spec.rb
|
316
288
|
- spec/lucid/app_spec.rb
|
data/lib/autotest/discover.rb
DELETED
data/lib/autotest/lucid.rb
DELETED
data/lib/autotest/lucid_mixin.rb
DELETED
@@ -1,134 +0,0 @@
|
|
1
|
-
require 'autotest'
|
2
|
-
require 'tempfile'
|
3
|
-
require 'lucid'
|
4
|
-
require 'lucid/cli/profile'
|
5
|
-
|
6
|
-
module Autotest::LucidMixin
|
7
|
-
def self.included(receiver)
|
8
|
-
receiver::ALL_HOOKS << [:run_specs, :ran_specs]
|
9
|
-
end
|
10
|
-
|
11
|
-
attr_accessor :specs_to_run
|
12
|
-
|
13
|
-
def initialize
|
14
|
-
super
|
15
|
-
reset_specs
|
16
|
-
end
|
17
|
-
|
18
|
-
def run
|
19
|
-
hook :initialize
|
20
|
-
reset
|
21
|
-
reset_specs
|
22
|
-
add_sigint_handler
|
23
|
-
|
24
|
-
self.last_mtime = Time.now if $f
|
25
|
-
|
26
|
-
loop do
|
27
|
-
begin
|
28
|
-
get_to_green
|
29
|
-
if self.tainted then
|
30
|
-
rerun_all_tests
|
31
|
-
rerun_all_specs if all_good
|
32
|
-
else
|
33
|
-
hook :all_good
|
34
|
-
end
|
35
|
-
wait_for_changes
|
36
|
-
# Once tests and specs are running green, this should reset specs
|
37
|
-
# every time a file is changed to see if anything breaks.
|
38
|
-
reset_specs
|
39
|
-
rescue Interrupt
|
40
|
-
break if self.wants_to_quit
|
41
|
-
reset
|
42
|
-
reset_specs
|
43
|
-
end
|
44
|
-
end
|
45
|
-
hook :quit
|
46
|
-
end
|
47
|
-
|
48
|
-
def all_specs_good
|
49
|
-
specs_to_run == ""
|
50
|
-
end
|
51
|
-
|
52
|
-
def get_to_green
|
53
|
-
begin
|
54
|
-
super
|
55
|
-
run_specs
|
56
|
-
wait_for_changes unless all_specs_good
|
57
|
-
end until all_specs_good
|
58
|
-
end
|
59
|
-
|
60
|
-
def rerun_all_specs
|
61
|
-
reset_specs
|
62
|
-
run_specs
|
63
|
-
end
|
64
|
-
|
65
|
-
def reset_specs
|
66
|
-
self.specs_to_run = :all
|
67
|
-
end
|
68
|
-
|
69
|
-
def run_specs
|
70
|
-
hook :run_specs
|
71
|
-
Tempfile.open('autotest-lucid') do |dirty_specs_file|
|
72
|
-
cmd = self.make_lucid_cmd(self.specs_to_run, dirty_specs_file.path)
|
73
|
-
return if cmd.empty?
|
74
|
-
puts cmd unless $q
|
75
|
-
old_sync = $stdout.sync
|
76
|
-
$stdout.sync = true
|
77
|
-
self.results = []
|
78
|
-
line = []
|
79
|
-
begin
|
80
|
-
open("| #{cmd}", "r") do |f|
|
81
|
-
until f.eof? do
|
82
|
-
c = f.getc or break
|
83
|
-
if RUBY_VERSION >= "1.9" then
|
84
|
-
print c
|
85
|
-
else
|
86
|
-
putc c
|
87
|
-
end
|
88
|
-
line << c
|
89
|
-
if c == ?\n then
|
90
|
-
self.results << if RUBY_VERSION >= "1.9" then
|
91
|
-
line.join
|
92
|
-
else
|
93
|
-
line.pack "c*"
|
94
|
-
end
|
95
|
-
line.clear
|
96
|
-
end
|
97
|
-
end
|
98
|
-
end
|
99
|
-
ensure
|
100
|
-
$stdout.sync = old_sync
|
101
|
-
end
|
102
|
-
self.specs_to_run = dirty_specs_file.read.strip
|
103
|
-
self.tainted = true unless self.specs_to_run == ''
|
104
|
-
end
|
105
|
-
hook :ran_specs
|
106
|
-
end
|
107
|
-
|
108
|
-
def make_lucid_cmd(specs_to_run, dirty_specs_filename)
|
109
|
-
return '' if specs_to_run == ''
|
110
|
-
|
111
|
-
profile_loader = Lucid::CLI::Profile.new
|
112
|
-
|
113
|
-
profile ||= "autotest-all" if profile_loader.has_profile?("autotest-all") && specs_to_run == :all
|
114
|
-
profile ||= "autotest" if profile_loader.has_profile?("autotest")
|
115
|
-
profile ||= nil
|
116
|
-
|
117
|
-
if profile
|
118
|
-
args = ["--profile", profile]
|
119
|
-
else
|
120
|
-
args = %w{--format} << (specs_to_run == :all ? "progress" : "standard")
|
121
|
-
end
|
122
|
-
# No --color option as some IDEs (Netbeans) don't output them very well ([31m1 failed step[0m)
|
123
|
-
args += %w{--format rerun --out} << dirty_specs_filename
|
124
|
-
args << (specs_to_run == :all ? "" : specs_to_run)
|
125
|
-
|
126
|
-
unless specs_to_run == :all
|
127
|
-
args << 'steps' << 'common'
|
128
|
-
end
|
129
|
-
|
130
|
-
args = args.join(' ')
|
131
|
-
|
132
|
-
return "#{Lucid::RUBY_BINARY} #{Lucid::BINARY} #{args}"
|
133
|
-
end
|
134
|
-
end
|
data/lib/autotest/lucid_rails.rb
DELETED
data/lib/autotest/lucid_rspec.rb
DELETED
@@ -1,20 +0,0 @@
|
|
1
|
-
require 'rspec/core'
|
2
|
-
|
3
|
-
# This file allows you to use all of RSpec's mocking frameworks. This
|
4
|
-
# essentially allows you to create test doubles which are used to
|
5
|
-
# stand in place of a production object during execution.
|
6
|
-
|
7
|
-
RSpec.configuration.configure_mock_framework
|
8
|
-
Domain(RSpec::Core::MockFrameworkAdapter)
|
9
|
-
|
10
|
-
Before do
|
11
|
-
RSpec::Mocks::setup(self)
|
12
|
-
end
|
13
|
-
|
14
|
-
After do
|
15
|
-
begin
|
16
|
-
RSpec::Mocks::verify
|
17
|
-
ensure
|
18
|
-
RSpec::Mocks::teardown
|
19
|
-
end
|
20
|
-
end
|
@@ -1,27 +0,0 @@
|
|
1
|
-
require 'optparse'
|
2
|
-
|
3
|
-
module Spec #:nodoc:
|
4
|
-
module Runner #:nodoc:
|
5
|
-
# Lucid uses OptionParser in order to parse any command line options.
|
6
|
-
# If RSpec is being used in any way with Lucid, then what will happen
|
7
|
-
# is that RSpec's option parser will kick in and try to parse ARGV.
|
8
|
-
# Since the command line arguments will be specific to Lucid, RSpec
|
9
|
-
# will not know what to do with them and will fail. So what this bit
|
10
|
-
# of logic is doing is making sure that the option parser for RSpec
|
11
|
-
# will not be operative.
|
12
|
-
class OptionParser < ::OptionParser #:nodoc:
|
13
|
-
MODDED_RSPEC = Object.new
|
14
|
-
def MODDED_RSPEC.method_missing(m, *args); self; end
|
15
|
-
|
16
|
-
def self.method_added(m)
|
17
|
-
unless @__modding_rspec
|
18
|
-
@__modding_rspec = true
|
19
|
-
define_method(m) do |*a|
|
20
|
-
MODDED_RSPEC
|
21
|
-
end
|
22
|
-
@__modding_rspec = false
|
23
|
-
end
|
24
|
-
end
|
25
|
-
end
|
26
|
-
end
|
27
|
-
end
|