alfredodeza / pytest.vim

Runs your UnitTests with py.test displaying red/green bars and errors
274 stars 40 forks source link

open terminal in new split for test #51

Closed jwkvam closed 5 years ago

jwkvam commented 7 years ago

Very nice plugin! Is it possible to run a test in a neovim terminal in a different window/split? I like to run with "-s" sometimes but when I do it reuses the split which contains the code I'm trying to test.

I managed to hack something myself. Maybe it'd be nice to have a config option? :)

    if has('nvim')
        exe ":vsp term://" . pdb_command
        exe ":startinsert"
    else
alfredodeza commented 6 years ago

Yeah, when I was using neovim this was very annoying, I would have to split first and then run my test, every time.

I'm inclined to say this is a problem with neovim (it is fine in vim). The problem with vsp is that a user might not want vsp and might prefer a horizontal split (sp) or to place a split in some other fashion (to the left, or the right, etc...)

alfredodeza commented 5 years ago

If using Vim 8, you get the full terminal support with correct window placement. I'm no longer using NeoVim and it is hard for me to support it now.