Split a string by whitespace but retain \n - Ruby
Michael Berkowski's comment on your question is correct.
If you want to work around this case, use a regular expression:
"Lorem ipsum\ndolor sit amet".split(/ /)
#=> ["Lorem", "ipsum\ndolor", "sit", "amet"]