Continuing in the vein of my last blog about Beware of Missing Gems in Rails! comes my discovery of – (dashes) being verboten in plugin names. About a month ago I looked at using Selenium On Rails in an app since I liked using it in the first one I worked on. However, I kept getting an error message:
The error occurred while evaluating
./script/../config/../vendor/rails/activesupport/lib/active_support/dependencies.rb:202:in 'load_file';from ./script/../config/../vendor/rails/activesupport/lib/active_support/dependencies.rb:94:in 'require_or_load';
So I gave up, thinking that it was because of some weird interaction with another plugin since I had so many installed for the project. Today I came back to it with a nice simple project, installed things and had the same error! Argh… So I joined the mailing list, looked around and found a post mentioning that in “Edge” Rails, which is now Rails 1.2.3 the name of the plugin needed to be changed from
selenium_on_rails! I’;ve looked around at some other plugins and realized that they all use
_ characters in the name!
Amazing how Rails can make life difficult over the most innocuous things. I am fairly sure this is never an issue in the Java world! Of course, every plugin would be implementing a very complex
IDynamicActiveReloadablePlugin interface 🙂