Skip to content

Commit a3f0aef

Browse files
authored
Merge pull request #330 from mashhurs/fix-buftok-spec-failures
Fixes the buftok spec failures caused by BufferTokenizer changes.
2 parents 1ae33d3 + 21f09a7 commit a3f0aef

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

spec/filewatch/buftok_spec.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,21 +5,21 @@
55

66
context "when using the default delimiter" do
77
it "splits the lines correctly" do
8-
expect(subject.extract("hello\nworld\n")).to eq ["hello", "world"]
8+
expect(subject.extract("hello\nworld\n").to_a).to eq ["hello", "world"]
99
end
1010

1111
it "holds partial lines back until a token is found" do
1212
buffer = described_class.new
13-
expect(buffer.extract("hello\nwor")).to eq ["hello"]
14-
expect(buffer.extract("ld\n")).to eq ["world"]
13+
expect(buffer.extract("hello\nwor").to_a).to eq ["hello"]
14+
expect(buffer.extract("ld\n").to_a).to eq ["world"]
1515
end
1616
end
1717

1818
context "when passing a custom delimiter" do
1919
subject { FileWatch::BufferedTokenizer.new("\r\n") }
2020

2121
it "splits the lines correctly" do
22-
expect(subject.extract("hello\r\nworld\r\n")).to eq ["hello", "world"]
22+
expect(subject.extract("hello\r\nworld\r\n").to_a).to eq ["hello", "world"]
2323
end
2424
end
2525
end

0 commit comments

Comments
 (0)