On May 13, 2011, at 15:24 , james b. wrote:

> I am making a gem and i have three files:
> 
> gem_name.rb
> gem_name/
>    version.rb
>    server.rb
> 
> in gem_name.rb it requires the other two files but for some reason on
> ruby 1.9.2 i can't find server but on 1.8.7 it can. I am using rvm and
> had a previously installed gem of the same name from when i was testing
> things so i thought that might be the problem so i reinstalled ruby
> 1.9.2 on rvm but the problem still persists.

Put everything in 'lib'. Put the tests (that you need to write) in 'test'.

lib/gem_name.rb should require like so:

require "gem_name/server"

when you run your tests (preferably via rake) make sure that "lib" is in your load path. 

ruby -Ilib test/gem_name/test_server.rb

and when you package this up as a gem, the "lib" dir should be in your gemspec's lib path.