ah ok, you wanted the test to test both. then lets just have a member variable but not use a getter method each time.

and lets have the constructor accept an optional $eolMarker that defaults to PHP_EOL. it could be useful for somebody in edge cases.