mirror of
https://github.com/meineerde/rackstash.git
synced 2025-12-19 15:01:12 +00:00
Clarify that the JSON encoder strips all whitespace
This commit is contained in:
parent
32b3ef8e0e
commit
e29c8976bb
@ -21,8 +21,8 @@ describe Rackstash::Encoders::JSON do
|
||||
expect(encoder.encode(event)).to eql '{"message":"text\nwith\nnewlines"}'
|
||||
end
|
||||
|
||||
it 'rstrips the message' do
|
||||
event = { 'message' => "line1\nline2\n \n\t\n" }
|
||||
it 'strips the message from all surpunding whitespace' do
|
||||
event = { 'message' => "\n\t \nline1\nline2\n \n\t\n" }
|
||||
expect(encoder.encode(event)).to eql '{"message":"line1\nline2"}'
|
||||
end
|
||||
end
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user