Skip to content

Commit 5735136

Browse files
committed
Prettier
1 parent 1bb591f commit 5735136

File tree

1 file changed

+3
-11
lines changed

1 file changed

+3
-11
lines changed

contrib/ruby_event_store-sequel/spec/event_repository_spec.rb

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,14 @@ module RubyEventStore
55
module Sequel
66
::RSpec.describe EventRepository do
77
helper = SpecHelper.new
8-
mk_repository = ->{ EventRepository.new(sequel: helper.sequel, serializer: helper.serializer) }
8+
mk_repository = -> { EventRepository.new(sequel: helper.sequel, serializer: helper.serializer) }
99

1010
it_behaves_like :event_repository, mk_repository, helper
1111

1212
around(:each) { |example| helper.run_lifecycle { example.run } }
1313

1414
let(:repository) { mk_repository.call }
15-
let(:specification) do
16-
Specification.new(
17-
SpecificationReader.new(repository, Mappers::Default.new)
18-
)
19-
end
15+
let(:specification) { Specification.new(SpecificationReader.new(repository, Mappers::Default.new)) }
2016

2117
specify "nested transaction - events still not persisted if append failed" do
2218
repository.append_to_stream(
@@ -41,11 +37,7 @@ module Sequel
4137
end
4238

4339
specify "avoid N+1" do
44-
repository.append_to_stream(
45-
[SRecord.new, SRecord.new],
46-
Stream.new("stream"),
47-
ExpectedVersion.auto
48-
)
40+
repository.append_to_stream([SRecord.new, SRecord.new], Stream.new("stream"), ExpectedVersion.auto)
4941

5042
expect { repository.read(specification.limit(2).result) }.to match_query_count(1)
5143
expect { repository.read(specification.limit(2).backward.result) }.to match_query_count(1)

0 commit comments

Comments
 (0)