Convert to RSpec, remove Rails deps for testing