gripmock
gripmock copied to clipboard
Fix inability to handle files with a trailing newline
Support for json arrays in the stub files was added previously, but it only worked with array files that did not end with a newline or files only containing a single non-array stub definition. Since all files written on linux will typically end in a newline this PR adds a rudimentary input sanitisation step while reading the file which fixes this.
Also tidy up some deprecations and add some more helpful error messages.