Skip to content

Commit

Permalink
Merge pull request #7 from nebulab/nirebu/add-ruby-3.2-test-matrix
Browse files Browse the repository at this point in the history
Add Ruby 3.2 to the test matrix
  • Loading branch information
nirebu authored Mar 13, 2023
2 parents d5d391e + 3ea5182 commit 29512a7
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
strategy:
fail-fast: false
matrix:
ruby-version: ['2.5', '2.6', '2.7', '3.0', '3.1']
ruby-version: ['2.5', '2.6', '2.7', '3.0', '3.1', '3.2']

steps:
- name: Checkout repository
Expand Down
12 changes: 6 additions & 6 deletions spec/unit/omnes/subscriber_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ def bar(_event)
it "subscribes to events matching with given matcher" do
bus.register(:foo)
subscriber_class.class_eval do
::TRUE_MATCHER = ->(_candidate) { true }
TRUE_MATCHER = ->(_candidate) { true }

handle_with_matcher TRUE_MATCHER, with: :foo

Expand All @@ -351,7 +351,7 @@ def foo(_event)
it "can provide id for the subscription" do
bus.register(:foo)
subscriber_class.class_eval do
::TRUE_MATCHER = ->(_candidate) { true }
TRUE_MATCHER = ->(_candidate) { true }

handle_with_matcher TRUE_MATCHER, with: :foo, id: :foo

Expand All @@ -370,7 +370,7 @@ def foo(_event); end
subscriber_class = Class.new do
include Omnes::Subscriber

::TRUE_MATCHER = ->(_candidate) { true }
TRUE_MATCHER = ->(_candidate) { true }

attr_reader :id_suffix

Expand All @@ -393,7 +393,7 @@ def foo(_event); end

it "raises when given subscription id has already been used" do
subscriber_class.class_eval do
::TRUE_MATCHER = ->(_candidate) { true }
TRUE_MATCHER = ->(_candidate) { true }

handle_with_matcher TRUE_MATCHER, with: :foo, id: :foo
handle_with_matcher TRUE_MATCHER, with: :foo, id: :foo
Expand All @@ -412,7 +412,7 @@ def foo(_event); end
it "builds the callback from a matching method when given a symbol" do
bus.register(:foo)
subscriber_class.class_eval do
::TRUE_MATCHER = ->(_candidate) { true }
TRUE_MATCHER = ->(_candidate) { true }

handle_with_matcher TRUE_MATCHER, with: :foo

Expand All @@ -433,7 +433,7 @@ def foo(_event)
it "builds the callback from given lambda" do
bus.register(:foo)
subscriber_class.class_eval do
::TRUE_MATCHER = ->(_candidate) { true }
TRUE_MATCHER = ->(_candidate) { true }

handle_with_matcher TRUE_MATCHER, with: ->(instance, event) { instance.method(:bar).(event) }

Expand Down

0 comments on commit 29512a7

Please sign in to comment.