Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
dd1ab83
Update CCK to v24
luke-hill May 15, 2026
5a7478e
Fix up breaking namespace changes, perform first run and document fin…
luke-hill May 15, 2026
39a50ce
Remove superfluous steps no longer needed in retryv24
luke-hill May 15, 2026
244a6fa
Add in granularity of retry sub-cck features
luke-hill May 15, 2026
010fd0d
Add 2 more sets of steps for new cck features
luke-hill May 15, 2026
b7e76c4
Add in final missing definition for missing feature
luke-hill May 15, 2026
e1d0e0a
Merge branch 'main' into refactor/upgrade_cck_v24
luke-hill May 25, 2026
aa607db
Updated run-set
luke-hill May 25, 2026
a5d615b
Add note for missing items whilst triaging
luke-hill May 25, 2026
d477018
Fix up missing duplicate step in cck definition for steps
luke-hill May 25, 2026
e0ac149
WIP: Generate snippets and suggestion with message output to event bu…
luke-hill May 25, 2026
afb247a
Always generate suggestion messages in background
luke-hill May 26, 2026
c13ee40
Fix snippet generation logic
luke-hill May 26, 2026
09920e3
Remove lots of cruft from snippet generation
luke-hill May 26, 2026
8e279bc
Add pickle step id into payload
luke-hill May 26, 2026
031a74f
Tidy up snippet generation into more bitesize methods
luke-hill May 26, 2026
3723989
Improve dual guard clause
luke-hill May 26, 2026
60765e4
Remove redundant guard clause. Snippets should never be empty if we h…
luke-hill May 26, 2026
f4474f1
Update running paradigms for CCKv24 conformance
luke-hill May 26, 2026
b7467a7
Fix up message formatter feature
luke-hill May 26, 2026
142ac2f
Merge branch 'main' into refactor/upgrade_cck_v24
luke-hill May 26, 2026
cf61e51
Memoize platform constants to avoid spam warnings
luke-hill May 26, 2026
8c00fb0
Fix up legacy ref to output_envelope
luke-hill May 26, 2026
f83424a
Fix CCK namespace and paths
luke-hill May 26, 2026
1f81410
Remove all erroneous namespaces out;
luke-hill May 26, 2026
952ed13
Fix up rubocop
luke-hill May 26, 2026
0609cde
Undo memoization guard
luke-hill May 27, 2026
5b469c7
Update changelog
luke-hill May 27, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,14 @@ Please visit [cucumber/CONTRIBUTING.md](https://github.com/cucumber/cucumber/blo
## [Unreleased]
### Added
- Print thread backtraces on SIGINFO/SIGPWR ([#1830](https://github.com/cucumber/cucumber-ruby/pull/1830)) [sobrinho](https://github.com/sobrinho)
- Added `Suggestion` messages that will show all the snippets for all message based formatters ([#1870](https://github.com/cucumber/cucumber-ruby/pull/1870)) [luke-hill](https://github.com/luke-hill)

### Changed
- Heavy refactor to the internals for message building (Used in formatters - should be no noticeable change)
([#1853](https://github.com/cucumber/cucumber-ruby/pull/1853) [luke-hill](https://github.com/luke-hill))
- Altered the concept of how `BeforeAll` and `AfterAll` hooks would run. They now attempt to all run before continuing test execution ([#1857](https://github.com/cucumber/cucumber-ruby/pull/1857) [brasmusson](https://github.com/brasmusson))
- Internal refactor to `MessageBuilder` class to send envelopes through event bus (Should be no noticeable change)
- Updated `cucumber-compatibility-kit` to v24

## [11.0.0] - 2026-04-14
### Added
Expand All @@ -36,7 +38,6 @@ Please visit [cucumber/CONTRIBUTING.md](https://github.com/cucumber/cucumber/blo
> The `rerun` formatter was chosen as the first formatter to migrate to this new structure as it is one of the simpler
> formatters and will allow us to test the new structure in a real-world scenario.
- Updated `cucumber-compatibility-kit` to v22
- Security: Switched out `IO.read` for more secure `File.read` in a few areas of the codebase
- Implemented the new cucumber-query structure in all message based formatters (Currently HTML / Rerun and Message)
([#1844](https://github.com/cucumber/cucumber-ruby/pull/1844) [luke-hill](https://github.com/luke-hill))

Expand All @@ -49,6 +50,9 @@ Please visit [cucumber/CONTRIBUTING.md](https://github.com/cucumber/cucumber/blo
- Fixed an issue where NoMethodError could be raised when declaring a parameter-type that used bound methods
([#1789](https://github.com/cucumber/cucumber-ruby/pull/1789))

### Security
- Switched out `IO.read` for more secure `File.read` in a few areas of the codebase

## [10.2.0] - 2025-12-10
### Changed
- Permit the latest version of the `cucumber-html-formatter` (v22.0.0+)
Expand Down
18 changes: 10 additions & 8 deletions compatibility/cck_spec.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true

require_relative 'support/shared_examples'
require_relative 'support/compatibility_kit'
require_relative 'support/cucumber/compatibility_kit'

require 'cucumber/compatibility_kit'

Expand All @@ -10,16 +10,18 @@
#
# All step definition and required supporting logic is contained here, the CCK gem proper contains the source of truth
# of the "golden" NDJSON files and attachments / miscellaneous files
RSpec.describe CCK, :cck do
RSpec.describe 'CCK', :cck do
let(:cucumber_command) { 'bundle exec cucumber --publish-quiet --profile none --format message' }

# CCK v22 conformance
# OVERALL: 93 examples, 0 failures, 93 passed
# SANITIZED: 84 examples, 0 failures, 84 passed
# CCK v24 conformance
# OVERALL: 111 examples, 2 failures, 109 passed
# SANITIZED: 108 examples, 0 failures, 108 passed

items_to_fix =
%w[]
_failing, passing = CompatibilityKit.gherkin.partition { |name| items_to_fix.include?(name) }
%w[
test-run-exception
]
_failing, passing = Cucumber::CompatibilityKit.gherkin.partition { |name| items_to_fix.include?(name) }

passing.each do |example_name|
describe "'#{example_name}' example" do
Expand All @@ -32,7 +34,7 @@
''
end
end
let(:support_code_path) { CompatibilityKit.supporting_code_for(example) }
let(:support_code_path) { Cucumber::CompatibilityKit.supporting_code_for(example) }
let(:messages) { `#{cucumber_command} --require #{support_code_path} #{cck_path} #{extra_args}` }
end
end
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# frozen_string_literal: true

Given('there are {int} cucumbers') do |initial_count|
@count = initial_count
end

When('I eat {int} cucumbers') do |eat_count|
@count -= eat_count
end

Then('I should have {int} cucumbers') do |expected_count|
expect(@count).to eq(expected_count)
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# frozen_string_literal: true

Before do
# no-op
end

After do
# no-op
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# frozen_string_literal: true

Given('an ambiguous step') do
# first one
end

Given('an ambiguous step') do
# second one
end
5 changes: 5 additions & 0 deletions compatibility/features/retry-pending/retry-pending_steps.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# frozen_string_literal: true

Given('a pending step') do
pending('')
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# frozen_string_literal: true

# There are intentionally no steps defined for this sample
12 changes: 0 additions & 12 deletions compatibility/features/retry/retry_steps.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,3 @@
Given('a step that always fails') do
raise 'Exception in step'
end

Given('an ambiguous step') do
# first one
end

Given('an ambiguous step') do
# second one
end

Given('a pending step') do
pending('')
end
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# frozen_string_literal: true

Given('a step') do
# no-op
end
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@

require 'rspec'
require 'cucumber/messages'
require_relative '../../support/cck/keys_checker'

RSpec.describe CCK::KeysChecker do
require_relative '../../../support/cucumber/compatibility_kit'

RSpec.describe Cucumber::CompatibilityKit::KeysChecker do
describe '#compare' do
let(:expected_kvps) { Cucumber::Messages::Attachment.new(url: 'https://foo.com', file_name: 'file.extension', test_step_id: 123_456) }
let(:missing_kvps) { Cucumber::Messages::Attachment.new(url: 'https://foo.com') }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@

require 'rspec'
require 'cucumber/messages'
require_relative '../../support/cck/messages_comparator'

RSpec.describe CCK::MessagesComparator do
require_relative '../../../support/cucumber/compatibility_kit'

RSpec.describe Cucumber::CompatibilityKit::MessagesComparator do
describe '#errors' do
context 'when executed as part of a CI' do
before { allow(ENV).to receive(:[]).with('CI').and_return(true) }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# frozen_string_literal: true

require_relative '../support/compatibility_kit'
require_relative '../../support/cucumber/compatibility_kit'

RSpec.describe CompatibilityKit do
let(:features_path) { File.expand_path("#{File.dirname(__FILE__)}/../features") }
RSpec.describe Cucumber::CompatibilityKit do
let(:features_path) { File.expand_path("#{File.dirname(__FILE__)}/../../features") }

describe '.supporting_code_for' do
context 'with an example that exists' do
Expand Down
19 changes: 0 additions & 19 deletions compatibility/support/cck/helpers.rb

This file was deleted.

62 changes: 0 additions & 62 deletions compatibility/support/cck/keys_checker.rb

This file was deleted.

102 changes: 0 additions & 102 deletions compatibility/support/cck/messages_comparator.rb

This file was deleted.

19 changes: 0 additions & 19 deletions compatibility/support/compatibility_kit.rb

This file was deleted.

Loading
Loading