why the IDE hides the spec folder in gems?
why the IDE hides the spec folder in gems?
Is there a way to unhide the spec folder. most of the times, the best documentation of a gem is found within
the test cases written for a gem. I would prefer the spec folder shown in the gem folder by default.
Please sign in to leave a comment.
Please see the screenshot.
Attachment(s):
rubymine_gems.png
Hi,
RubyMine tries to avoid redundant files parsing/indexing, so it ignores tests in gems folders. And usually people don't need them. So you have several options
1. Open necessary test/folder using RubyMine "Navigation Bar"
2. Reveal in "Finder" from context menu
3. Open gem as new separate project (File | Open Directory)
There are issues with all the options.
#1. Navigation Bar shows only the project directory. It does not show the gem directory.
#2. I cannot find Finder on right click, on the selected gem in the External Libraries node. ( please refer the attachment).
#3. Highly inconvenient option. Need to switch between the windows.
I know it is the IDE limitation that it cannot open 2 rails projects in one window, but I managed to open 2 ruby projects in one window by adding the second project as a folder.
Navbar autoshow directory/file selected in current context. You are right it doesn't work on library node (I think we need to fix it) but you may select gem "lib" subfolder
and then
more over you can quickly open non-project files, e.g. click on '/' folder icon and search necessary path
Again please choose file/folder node instead of library name node:
Ok, I agree. But it may be convenient if you want to launch tests, fix smth, etc.
Please avoid such configuration. RubyMine recognize rails project and provides rails related features only if rails project is project root dir. It is possible to add other folders as project content roots, but rails support won't be available for them. To add 2nd and other roots please open File | Settings | Project Structure | Add Content Root
Thanks. I disabled Navigation Bar earlier. I could get to spec folder using the Nav Bar.
FYI, regarding the Reveal in Finder, on LinuxMint, it says
Show in Nautilus
and opens that directory in a File Explorer.
It would be nice if one the spec folder was selected, that the project nav would be populated. Often I define local gems in my Gemfile and add features locally.