$ python3 csv_roundtrip.py fixtures/memos.json p14_run_01
exit=0
stdout:
{
  "header": [
    "id",
    "qty",
    "memo"
  ],
  "data_records": 2,
  "fields_per_record": 3,
  "physical_lines": 4,
  "record_terminator": "CRLF",
  "roundtrip_equal": true
}
stderr:

input_unchanged=True

$ python3 csv_roundtrip.py fixtures/memos.json p14_run_02
exit=0
stdout:
{
  "header": [
    "id",
    "qty",
    "memo"
  ],
  "data_records": 2,
  "fields_per_record": 3,
  "physical_lines": 4,
  "record_terminator": "CRLF",
  "roundtrip_equal": true
}
stderr:

input_unchanged=True

$ python3 csv_roundtrip.py fixtures/crlf_memo.json crlf_memo
exit=0
stdout:
{
  "header": [
    "id",
    "qty",
    "memo"
  ],
  "data_records": 2,
  "fields_per_record": 3,
  "physical_lines": 4,
  "record_terminator": "CRLF",
  "roundtrip_equal": true
}
stderr:

input_unchanged=True

$ python3 csv_roundtrip.py fixtures/empty_memo.json empty_memo
exit=0
stdout:
{
  "header": [
    "id",
    "qty",
    "memo"
  ],
  "data_records": 2,
  "fields_per_record": 3,
  "physical_lines": 3,
  "record_terminator": "CRLF",
  "roundtrip_equal": true
}
stderr:

input_unchanged=True

$ python3 csv_roundtrip.py fixtures/final_lf_memo.json final_lf_memo
exit=0
stdout:
{
  "header": [
    "id",
    "qty",
    "memo"
  ],
  "data_records": 2,
  "fields_per_record": 3,
  "physical_lines": 4,
  "record_terminator": "CRLF",
  "roundtrip_equal": true
}
stderr:

input_unchanged=True

$ python3 csv_roundtrip.py fixtures/comma_quotes.json comma_quotes
exit=0
stdout:
{
  "header": [
    "id",
    "qty",
    "memo"
  ],
  "data_records": 2,
  "fields_per_record": 3,
  "physical_lines": 3,
  "record_terminator": "CRLF",
  "roundtrip_equal": true
}
stderr:

input_unchanged=True

$ python3 csv_roundtrip.py fixtures/formula_string.json formula_string
exit=0
stdout:
{
  "header": [
    "id",
    "qty",
    "memo"
  ],
  "data_records": 1,
  "fields_per_record": 3,
  "physical_lines": 2,
  "record_terminator": "CRLF",
  "roundtrip_equal": true
}
stderr:

input_unchanged=True

$ python3 csv_roundtrip.py fixtures/blank_row_invalid.json blank_row_invalid
exit=2
stdout:
stderr:
ERROR: JSON row 1 must be a list of three fields

input_unchanged=True

$ python3 csv_roundtrip.py fixtures/nonstring_invalid.json nonstring_invalid
exit=2
stdout:
stderr:
ERROR: JSON row 1: all fields must be strings; null is rejected

input_unchanged=True

$ python3 csv_roundtrip.py fixtures/invalid_null.json invalid_null
exit=2
stdout:
stderr:
ERROR: JSON row 1: all fields must be strings; null is rejected

input_unchanged=True

$ python3 csv_roundtrip.py fixtures/malformed_invalid.json malformed_invalid
exit=2
stdout:
stderr:
ERROR: invalid JSON: Expecting ',' delimiter: line 2 column 1 (char 21)

input_unchanged=True

$ python3 csv_roundtrip.py fixtures/memos.json p14_run_01
exit=2 (existing output collision)
ERROR: [Errno 17] File exists: '/tmp/p14_csv_verify_ygr6dhyr/p14_run_01'
