Closed bo-oz closed 8 years ago
It's an issue, it looks like something broke that key binding :( Can't take a look until weekend arrives though. Thanks for the heads up!
Thanks for taking a look. Great package though!
I found the same thing... If I already have two panes open, AND my primary file is active in the left-hand pane, then ruby-test-switcher:switch
correctly opens the test in the right-hand pane.
However, if the test is already in the left-hand pane, or there's only a single pane open, then the test is just opened in in the same pane.
Took a bit of time to figure out. Now that I know to keep my primary files in the left-hand pane, and to always keep a second pane open, it seems to work pretty well.
@bo-oz Sorry for the delay getting back to you. Are you still experiencing the same issue? I've just re-tested it in both Windows and Mac OS X and looks fine. Still same default keybindings, so don't know what could be producing it. Perhaps a conflict with another package? Using Atom's keybinding resolver might come handy in that case.
@bronson What you describe is the expected behavior, since I directly implemented the switching according to my workflow:
1) Source code to the left pane & test code to the right pane. 2) Switch to already opened (if any) source/test file, so I can bypass the default left/right locations.
This means: even if there are 2 opened panes, when the command is triggered from a source file located in the right pane, test file should be opened in the same pane.
Is this something that disturbs you / doesn't fit within your usual workflow? We could set the default pane locations as a configurable setting if that helps mitigating the issue.
Anyways, we should explicitly document it in the README file. Thanks for the heads up ;)
Well, it's surprising behavior when "open in new pane" doesn't actually do that. I suppose you could change the command to be switch-as-long-as-current-file-is-primary-and-in-left-hand-pane
:)
I like my tools small and sharp. I don't really want them imposing their workflow upon me... Then they require long READMEs and end up feeling like an IDE.
Thanks for the explanation!
Thank you for your feedback and feel free to contribute. Both Atom and this package would benefit from further contributions.
I don't know if this is really an issue... but when I'm trying to switch to the test from my code using Ctrl + Cmd + . when viewing a single pane (as I'm usually doing), the test isn't opened in the other (new) pane, but in the same pane as a tab.