ray-x / go.nvim

G'day Nvimer, Joyful Gopher: Discover the Feature-Rich Go Plugin for Neovim
MIT License
1.93k stars 119 forks source link

GoTest shows failure on passing test #379

Open lancekrogers opened 10 months ago

lancekrogers commented 10 months ago

Running :GoTest on a test that has no failures is showing the below error

Screenshot 2023-09-21 at 12 55 05 PM

The test with not modification passes when go test ./... is run direction from the command line

Screenshot 2023-09-21 at 1 21 06 PM

I am experiencing this with commit 5e9e083 but don't know when it started. I first noticed this issue yesterday after updating lunarvim.

ray-x commented 10 months ago

Is the folder in first screen shot looks correct? what is the current working folder in nvim when you run the tests?

lancekrogers commented 10 months ago

Yes the folder is correct, when I run :lua print(vim.loop.cwd()) the output is ~/{user}/Dev/learn-go-with-tests

eduardosanzb commented 9 months ago

I was having same issues; but I ensure that I was running inside the same directory as my golang project (working in a monorepo) and then worked fine!

Would be a way to change the root for GoTest?