cucumber-core 3.0.0 → 3.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/cucumber/core/version.rb +1 -1
- metadata +19 -85
- data/.coveralls.yml +0 -1
- data/.github/ISSUE_TEMPLATE.md +0 -48
- data/.github/PULL_REQUEST_TEMPLATE.md +0 -39
- data/.rspec +0 -1
- data/.ruby-gemset +0 -1
- data/.travis.yml +0 -30
- data/.yardopts +0 -6
- data/Gemfile +0 -2
- data/Rakefile +0 -28
- data/cucumber-core.gemspec +0 -36
- data/spec/capture_warnings.rb +0 -74
- data/spec/coverage.rb +0 -11
- data/spec/cucumber/core/ast/background_spec.rb +0 -11
- data/spec/cucumber/core/ast/data_table_spec.rb +0 -81
- data/spec/cucumber/core/ast/doc_string_spec.rb +0 -114
- data/spec/cucumber/core/ast/empty_multiline_argument_spec.rb +0 -28
- data/spec/cucumber/core/ast/examples_table_spec.rb +0 -113
- data/spec/cucumber/core/ast/location_spec.rb +0 -199
- data/spec/cucumber/core/ast/outline_step_spec.rb +0 -93
- data/spec/cucumber/core/ast/step_spec.rb +0 -174
- data/spec/cucumber/core/compiler_spec.rb +0 -267
- data/spec/cucumber/core/event_bus_spec.rb +0 -163
- data/spec/cucumber/core/event_spec.rb +0 -40
- data/spec/cucumber/core/filter_spec.rb +0 -101
- data/spec/cucumber/core/gherkin/parser_spec.rb +0 -261
- data/spec/cucumber/core/gherkin/writer_spec.rb +0 -333
- data/spec/cucumber/core/report/summary_spec.rb +0 -175
- data/spec/cucumber/core/test/action_spec.rb +0 -154
- data/spec/cucumber/core/test/case_spec.rb +0 -316
- data/spec/cucumber/core/test/duration_matcher.rb +0 -20
- data/spec/cucumber/core/test/filters/locations_filter_spec.rb +0 -405
- data/spec/cucumber/core/test/result_spec.rb +0 -474
- data/spec/cucumber/core/test/runner_spec.rb +0 -310
- data/spec/cucumber/core/test/step_spec.rb +0 -98
- data/spec/cucumber/core/test/timer_spec.rb +0 -25
- data/spec/cucumber/core_spec.rb +0 -262
- data/spec/readme_spec.rb +0 -37
- data/spec/report_api_spy.rb +0 -25
data/spec/readme_spec.rb
DELETED
@@ -1,37 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
require 'stringio'
|
3
|
-
require 'kramdown'
|
4
|
-
|
5
|
-
describe "README.md code snippet" do
|
6
|
-
let(:code_blocks) do
|
7
|
-
markdown = File.read(File.expand_path(File.dirname(__FILE__) + '/../README.md'))
|
8
|
-
parse_ruby_from(markdown)
|
9
|
-
end
|
10
|
-
|
11
|
-
it "executes with the expected output" do
|
12
|
-
code, output = *code_blocks
|
13
|
-
expect(execute_ruby(code)).to eq output
|
14
|
-
end
|
15
|
-
|
16
|
-
def execute_ruby(code)
|
17
|
-
capture_stdout do
|
18
|
-
eval code, binding
|
19
|
-
end
|
20
|
-
end
|
21
|
-
|
22
|
-
def parse_ruby_from(markdown)
|
23
|
-
code_blocks = Kramdown::Parser::GFM.parse(markdown).first.children.select { |e| e.type == :codeblock }.map(&:value)
|
24
|
-
expect(code_blocks).not_to be_empty
|
25
|
-
code_blocks
|
26
|
-
end
|
27
|
-
|
28
|
-
def capture_stdout
|
29
|
-
original = $stdout
|
30
|
-
$stdout = StringIO.new
|
31
|
-
yield
|
32
|
-
result = $stdout.string
|
33
|
-
$stdout = original
|
34
|
-
result
|
35
|
-
end
|
36
|
-
|
37
|
-
end
|
data/spec/report_api_spy.rb
DELETED
@@ -1,25 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
class ReportAPISpy
|
3
|
-
def initialize
|
4
|
-
@result = []
|
5
|
-
end
|
6
|
-
|
7
|
-
def test_case(*args)
|
8
|
-
@result << [:test_case, *args]
|
9
|
-
yield self if block_given?
|
10
|
-
end
|
11
|
-
|
12
|
-
def test_step(*args)
|
13
|
-
@result << [:test_step, *args]
|
14
|
-
yield self if block_given?
|
15
|
-
end
|
16
|
-
|
17
|
-
def done(*args)
|
18
|
-
@result << [:done, *args]
|
19
|
-
yield self if block_given?
|
20
|
-
end
|
21
|
-
|
22
|
-
def messages
|
23
|
-
@result.map(&:first)
|
24
|
-
end
|
25
|
-
end
|