Skip to content

Conversation

TotalKnob
Copy link

Fix for merging an array of fields into the destination using the merge mutation.

I have included a test which produces the following failure prior to the fix:

LogStash::Filters::Mutate merge multiple fields into string field "{\"foo\":\"bar\",\"spam\":\"ham\",\"list\":\"baz\"}" processes events as specified
     Failure/Error: expect(subject.get("list")).to eq ["baz", "bar", "ham"]
     
       expected: ["baz", "bar", "ham"]
            got: ["baz", "ham"]
     
       (compared using ==)
     # ./spec/filters/mutate_spec.rb:1092:in `block in <main>'

Test passes after the fix.

Fixes #167

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Merging Multiple Fields Fails
2 participants