You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am creating a neotest adapter to run Odin tests in neovim.
Using neotest it is possible to run individual tests, by file or by directory, when I run the tests by file I cannot use the -file flag because some tests may depend on other files, so I am using the -define:ODIN_TEST_NAMES=main.test_part01 flag, I also cannot use -define:ODIN_TEST_NAMES=main.test_part01,main.test_part02 because the tests need to run separately.
At this point I encountered a problem, because neotest runs the tests in parallel, and the odin test command does not behave as it should.
Finished 1 test in 160.542µs. The test was successful.
[ERROR] --- [2024-12-24 18:57:29] [main_test.odin:34:test_part02()] Part Two: 4
Finished 1 test in 186.031µs. The test failed.
- main.test_part02 Part Two: 4
Current Behavior
Only one of the tests runs in both cases, sometimes both pass and sometimes both fail.
Finished 1 test in 160.542µs. The test was successful.
Finished 1 test in 183.505µs. The test was successful.
[ERROR] --- [2024-12-24 18:57:29] [main_test.odin:34:test_part02()] Part Two: 4
Finished 1 test in 202.932µs. The test failed.
- main.test_part02 Part Two: 4
[ERROR] --- [2024-12-24 18:57:29] [main_test.odin:34:test_part02()] Part Two: 4
Finished 1 test in 186.031µs. The test failed.
- main.test_part02 Part Two: 4
sh: line 1: /home/su3h7am/Projects/advent-of-code/day02: Text file busy
Context
I am creating a
neotest
adapter to run Odin tests inneovim
.Using
neotest
it is possible to run individual tests, by file or by directory, when I run the tests by file I cannot use the-file
flag because some tests may depend on other files, so I am using the-define:ODIN_TEST_NAMES=main.test_part01
flag, I also cannot use-define:ODIN_TEST_NAMES=main.test_part01,main.test_part02
because the tests need to run separately.At this point I encountered a problem, because
neotest
runs the tests in parallel, and theodin test
command does not behave as it should.To reproduce
Expected Behavior
Only one of the tests must pass
Current Behavior
Only one of the tests runs in both cases, sometimes both pass and sometimes both fail.
Operating System & Odin Version:
The text was updated successfully, but these errors were encountered: