0

I have a .txt file that I'd like to unit test. Is there a way with OCMock to make a "fake" test files for testing purposes? The behavior of my application depends on whats in the text file and ideally I'd like to write a unit test with different variations of the text file to test to make sure it works in all cases. The text file has a fixed name and file path.

e1985
  • 6,239
  • 1
  • 24
  • 39
user1802143
  • 14,662
  • 17
  • 46
  • 55
  • 1
    How do you want to read the file content? Line by line or just load it in a string? – e1985 Aug 13 '13 at 10:14
  • Do you mean you have a real text file for production, but would like to specify a fake text for for testing? – Jon Reid Aug 17 '13 at 15:59

0 Answers0