Add ruby-version file
Moved test code out of lib