Test output contains no newlines

When I run tests in GoLand (2018.2.3) all newlines are stripped away, putting all output on a single line. How can I change this?

For example, while the terminal gets me this:

--- FAIL: TestMaterialization (25.62s)
    --- PASS: TestMaterialization/Test_#000:_COST___Valid_json (0.02s)
    --- PASS: TestMaterialization/Test_#001:_COST___Valid_json_-_with_retail_store (0.03s)
    --- PASS: TestMaterialization/Test_#002:_BRAND___json_-_well-formed (0.02s)
    --- PASS: TestMaterialization/Test_#003:_ITEM___json_-_well-formed (0.02s)
    --- PASS: TestMaterialization/Test_#004:_ITEM___csv_with_duplicate_PK (0.05s)
    --- PASS: TestMaterialization/Test_#005:_PRICE___json_-_well-formed (0.04s)
    --- PASS: TestMaterialization/Test_#006:_PRICE___json_-_well-formed_with_retail_store (0.02s)
    --- PASS: TestMaterialization/Test_#007:_PROMOTION___json (0.00s)
        materializer_test.go:69: Skipping fact 0 (not a fact.Fact)
        materializer_test.go:72: Skipping fact 0 (no materializer for subject UNKNOWN_SUBJECT)
    --- PASS: TestMaterialization/Test_#008:_PROMOTION___json_with_duplicated_associations (0.00s)
        materializer_test.go:69: Skipping fact 0 (not a fact.Fact)
        materializer_test.go:72: Skipping fact 0 (no materializer for subject UNKNOWN_SUBJECT)
    --- PASS: TestMaterialization/Test_#009:_PROMOTION___json-2 (0.20s)
    --- PASS: TestMaterialization/Test_#010:_PROMOTION___json-3 (0.35s)
    --- PASS: TestMaterialization/Test_#011:_PROMOTION___json-4 (0.22s)
    --- PASS: TestMaterialization/Test_#012:_PROMOTION___json-5 (0.29s)
    --- PASS: TestMaterialization/Test_#013:_PROMOTION___json-6 (0.35s)
    --- PASS: TestMaterialization/Test_#014:_PROMOTION___json-7 (0.33s)
    --- PASS: TestMaterialization/Test_#015:_PROMOTION___json-8 (0.57s)
    --- PASS: TestMaterialization/Test_#016:_PROMOTION___json-9 (0.40s)
    --- PASS: TestMaterialization/Test_#017:_PROMOTION___jsonarray-2 (0.31s)
    --- PASS: TestMaterialization/Test_#018:_PROMOTION___promotion_that_used_to_get_multiple_tactic_types (0.48s)
    --- PASS: TestMaterialization/Test_#019:_RETAIL_STORE___json_-_well-formed_(II) (0.05s)
    --- PASS: TestMaterialization/Test_#020:_SUPPLIER___json_-_well-formed (0.02s)
    --- FAIL: TestMaterialization/Test_#021:_SUPPLIER_FUNDING___json_-_well-formed (0.02s)
        materializer_test.go:85: could not start query workers: could not create temporary table: pq: type "supplier_funding_logic_enum" does not exist, query context: "z5j14p (
                                        external_supplier_funding_id    text,
                                        external_supplier_id            text,
                                        external_item_id                text,
                                        external_retail_store_id        text,
                                        external_promotion_id           text,
                                        logic                           supplier_funding_logic_enum,
                                        "value"                         double precision
                                )"
    --- PASS: TestMaterialization/Test_#022:_TRANSACTION___json_-_well-formed (0.07s)
    --- PASS: TestMaterialization/Test_#023:_TRANSACTION_FLAT___json_array (0.08s)
    --- PASS: TestMaterialization/Test_#024:_repeated_promotion_insert (0.61s)
        materializer_test.go:55: Running subtest 1/2: json-7
        materializer_test.go:55: Running subtest 2/2: json-7
    --- PASS: TestMaterialization/Test_#025:_brand_synonym_handling (0.07s)
        materializer_test.go:55: Running subtest 1/2: synonyms part 1
        materializer_test.go:55: Running subtest 2/2: synonyms part 2
    --- PASS: TestMaterialization/Test_#026:_supplier_synonym_handling (0.04s)
        materializer_test.go:55: Running subtest 1/2: synonyms part 1
        materializer_test.go:55: Running subtest 2/2: synonyms part 2
    --- PASS: TestMaterialization/Test_#027:_repeated_promotion_insert_—_different_tactics (0.52s)
        materializer_test.go:55: Running subtest 1/2: promotion that used to get multiple tactic types
        materializer_test.go:55: Running subtest 2/2: promotion that used to get multiple tactic types
FAIL
FAIL    github.com/formulatehq/materializer/internal    26.729s

GoLand outputs this:

=== RUN   TestMaterialization
{"Time":"2018-10-10T14:26:12.061464519+02:00","Action":"run   testmaterialization/test_#000","Test":"_COST___Valid_json"}{"Time":"2018-10-10T14:26:12.702088366+02:00","Action":"run   testmaterialization/test_#001","Test":"_COST___Valid_json_-_with_retail_store"}{"Time":"2018-10-10T14:26:13.353958858+02:00","Action":"run   testmaterialization/test_#002","Test":"_BRAND___json_-_well-formed"}{"Time":"2018-10-10T14:26:13.980247779+02:00","Action":"run   testmaterialization/test_#003","Test":"_ITEM___json_-_well-formed"}{"Time":"2018-10-10T14:26:14.9407671+02:00","Action":"run   testmaterialization/test_#004","Test":"_ITEM___csv_with_duplicate_PK"}{"Time":"2018-10-10T14:26:15.632979408+02:00","Action":"run   testmaterialization/test_#005","Test":"_PRICE___json_-_well-formed"}{"Time":"2018-10-10T14:26:16.589475159+02:00","Action":"run   testmaterialization/test_#006","Test":"_PRICE___json_-_well-formed_with_retail_store"}{"Time":"2018-10-10T14:26:17.371097551+02:00","Action":"run   testmaterialization/test_#007","Test":"_PROMOTION___json"}{"Time":"2018-10-10T14:26:18.052402978+02:00","Action":"run   testmaterialization/test_#008","Test":"_PROMOTION___json_with_duplicated_associations"}{"Time":"2018-10-10T14:26:18.854029805+02:00","Action":"run   testmaterialization/test_#009","Test":"_PROMOTION___json-2"}{"Time":"2018-10-10T14:26:19.858648314+02:00","Action":"run   testmaterialization/test_#010","Test":"_PROMOTION___json-3"}{"Time":"2018-10-10T14:26:20.750979316+02:00","Action":"run   testmaterialization/test_#011","Test":"_PROMOTION___json-4"}{"Time":"2018-10-10T14:26:21.464077878+02:00","Action":"run   testmaterialization/test_#012","Test":"_PROMOTION___json-5"}{"Time":"2018-10-10T14:26:22.103648097+02:00","Action":"run   testmaterialization/test_#013","Test":"_PROMOTION___json-6"}{"Time":"2018-10-10T14:26:22.985932784+02:00","Action":"run   testmaterialization/test_#014","Test":"_PROMOTION___json-7"}{"Time":"2018-10-10T14:26:23.691899676+02:00","Action":"run   testmaterialization/test_#015","Test":"_PROMOTION___json-8"}{"Time":"2018-10-10T14:26:24.300960849+02:00","Action":"run   testmaterialization/test_#016","Test":"_PROMOTION___json-9"}{"Time":"2018-10-10T14:26:24.955266966+02:00","Action":"run   testmaterialization/test_#017","Test":"_PROMOTION___jsonarray-2"}{"Time":"2018-10-10T14:26:25.631099155+02:00","Action":"run   testmaterialization/test_#018","Test":"_PROMOTION___promotion_that_used_to_get_multiple_tactic_types"}{"Time":"2018-10-10T14:26:26.302913645+02:00","Action":"run   testmaterialization/test_#019","Test":"_RETAIL_STORE___json_-_well-formed_(II)"}{"Time":"2018-10-10T14:26:26.826685443+02:00","Action":"run   testmaterialization/test_#020","Test":"_SUPPLIER___json_-_well-formed"}{"Time":"2018-10-10T14:26:27.529703765+02:00","Action":"run   testmaterialization/test_#021","Test":"_SUPPLIER_FUNDING___json_-_well-formed"}{"Time":"2018-10-10T14:26:28.08279645+02:00","Action":"run   testmaterialization/test_#022","Test":"_TRANSACTION___json_-_well-formed"}{"Time":"2018-10-10T14:26:28.730569877+02:00","Action":"run   testmaterialization/test_#023","Test":"_TRANSACTION_FLAT___json_array"}{"Time":"2018-10-10T14:26:29.235738584+02:00","Action":"run   testmaterialization/test_#024","Test":"_repeated_promotion_insert"}{"Time":"2018-10-10T14:26:30.567718678+02:00","Action":"run   testmaterialization/test_#025","Test":"_brand_synonym_handling"}{"Time":"2018-10-10T14:26:31.375782737+02:00","Action":"run   testmaterialization/test_#026","Test":"_supplier_synonym_handling"}{"Time":"2018-10-10T14:26:32.150166719+02:00","Action":"run   testmaterialization/test_#027","Test":"_repeated_promotion_insert_—_different_tactics"}--- FAIL: TestMaterialization (21.12s)
FAIL
3 comments
Comment actions Permalink

Hi Christofer,

Looks like a bug. Not sure which tool is to blame yet. Could you please run the exact command that GoLand does in the terminal and attach the output here? Or please give a link to a project to recreate the problem, if it's open-source.

1
Comment actions Permalink

Hi Alexander,

Thanks for the quick response!

While trying and failing to reproduce the problem in a new project, I happened to solve it by deleting the `.idea` directory in the project root and reload the application. I have worked on the project for a long time, so there must have been lingering junk in the workspace from older versions of GoLand. Will try this trick in the future before reporting any other issues with the IDE.

0
Comment actions Permalink

Hi,

Sure, if you'll face the issue again feel free to ping me here or drop an email to zolotov@jetbrains.com with .idea/ directory and steps to recreate the issue.

Thanks!

0

Please sign in to leave a comment.