'testing.logF logging doesn't work when debugging tests in vs code go
We have some go tests written in our repo that I am trying to debug. We mostly use logF from testing.T package for logging purposes. I am trying to debug tests using "Debug Test" button in VS code and expect to see logs in Debug Console window. (check screenshot below)
"Debug Test" button in Vs code
When I click on "Debug Tests", this is the command that runs in Debug Console
{work_dir}/bin/dlv dap --check-go-version=false --listen=127.0.0.1:36859 --log-dest=3 from {test_path}
I don't see logs using logF method showing up in Debug Console. However logs from fmt.Println shows up in Debug Console.
I have tried multiple dlv log options (from dlv log help) but don't see anything working for me. Does logF logging work in dlv debugging?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
