This post is about how you can use Neovim to have refactoring tooling inspired in Refactoring and your tooling from Learn Go with tests.
Extract/Inline #I am using refactoring.nvim plugin.
Extract Variable #vim.keymap.set("x", "rv", function() require('refactoring').refactor('Extract Variable') end) You need to select the part of your code that you want to extract to a variable and then press rv.