The Ruby gem tool follows a path detection algorithm that is apparently not Windows (as I see from your ruby -v
).
You can get a clear image if you trace, for example, loading a Rails application using ProcMon . Each (I really mean each) require
runs a scan across all directories in the Ruby path plus all gem directories. A typical require
takes 20 ms on an average computer. Because Rails is hundreds of require
s, those 20 ms are easy to add up to seconds every time you start the Rails framework. Take the time to initialize the fixtures in the database, and you will get a better idea of โโwhy it takes so long to start running test cases.
Perhaps due to each architecture and file system implementation (path caching, etc.) this is less of a problem on Linux than on Windows. However, I do not know who you are blaming. It looks like the NTFS file system can be improved with a better implementation of path caching, but obviously the gem tool can implement the caching itself and have performance that is not so platform dependent.
source share