I need to compare two strings ignoring whitespaces and newline characters, so the following strings should be equal:
"Initial directory structure.\r\n \r\n The directory tree has been changed"
"Initial directory structure.\n\nThe directory tree has been changed"
How can I implement it?