File: camelize_spec.rb

package info (click to toggle)
ruby-inflecto 0.0.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 236 kB
  • sloc: ruby: 691; makefile: 2
file content (21 lines) | stat: -rw-r--r-- 667 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
require 'spec_helper'

describe Inflecto do
  describe '.camelize' do
    it 'camelizes data_mapper as DataMapper' do
      Inflecto.camelize('data_mapper').should == 'DataMapper'
    end

    it 'camelizes merb as Merb' do
      Inflecto.camelize('merb').should == 'Merb'
    end

    it 'camelizes data_mapper/resource as DataMapper::Resource' do
      Inflecto.camelize('data_mapper/resource').should == 'DataMapper::Resource'
    end

    it 'camelizes data_mapper/associations/one_to_many as DataMapper::Associations::OneToMany' do
      Inflecto.camelize('data_mapper/associations/one_to_many').should == 'DataMapper::Associations::OneToMany'
    end
  end
end