This PR should allow us to test all of the RSpec examples included within this adapter, automatically using Plenary. It is heavily inspired by the way that Refactoring.nvim works.
Currently, we have a directory of RSpec tests which we manually test against to verify that the adapter is working as intended. This is currently done manually and is incredibly time consuming. Also, if a user adds a test case that the adapter doesn't work with, you enter into the world of restarting Neovim over again and triggering neotest.
This PR proposes that each of the files in the RSpec tests dir has the following accompaniments:
a *.commandsfile - whereby the commands to trigger neotest reside
a *.expected file - which contains the output we expect from neotest
a *_spec.start.rb file - which contains the RSpec test itself
Within a Plenary test file, we loop through all of the the files in the RSpec tests dir and assert that the output from running :lua require("neotest").run.run() matches that in the *.expected file.
This PR should allow us to test all of the RSpec examples included within this adapter, automatically using Plenary. It is heavily inspired by the way that Refactoring.nvim works.
Currently, we have a directory of RSpec tests which we manually test against to verify that the adapter is working as intended. This is currently done manually and is incredibly time consuming. Also, if a user adds a test case that the adapter doesn't work with, you enter into the world of restarting Neovim over again and triggering neotest.
This PR proposes that each of the files in the RSpec tests dir has the following accompaniments:
*.commands
file - whereby the commands to trigger neotest reside*.expected
file - which contains the output we expect from neotest*_spec.start.rb
file - which contains the RSpec test itselfWithin a Plenary test file, we loop through all of the the files in the RSpec tests dir and assert that the output from running
:lua require("neotest").run.run()
matches that in the*.expected
file.