Skip to content

Commit

Permalink
Use concurrent stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
joeldrapper committed Oct 23, 2024
1 parent d5ca159 commit 93ab867
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions lib/quickdraw.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

require "concurrent/map"
require "concurrent/array"
require "concurrent/set"

module Quickdraw
autoload :ArgumentError, "quickdraw/errors/argument_error"
Expand Down
4 changes: 2 additions & 2 deletions lib/quickdraw/context.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def matchers
@matchers ||= if superclass < Quickdraw::Context
superclass.matchers.dup
else
Set[]
Concurrent::Set.new
end
end

Expand All @@ -39,7 +39,7 @@ def initialize(name, skip, runner, matchers)
@runner = runner
@matchers = matchers

@expectations = []
@expectations = Concurrent::Array.new
end

def expect(value = Quickdraw::Null, &block)
Expand Down

0 comments on commit 93ab867

Please sign in to comment.