Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 29 lines (16 sloc) 0.85 kb
f8760b7 @ryanb adding some documentation for running specs with different model adapter...
authored
1 = CanCan Specs
2
3 == Running the specs
4
5 To run the specs first run the +bundle+ command to install the necessary gems and the +rake+ command to run the specs.
6
7 bundle
8 rake
9
10 The specs currently require Ruby 1.8.7. Ruby 1.9.2 support will be coming soon.
11
12
13 == Model Adapters
14
15 CanCan offers separate specs for different model adapters (such as Mongoid and Data Mapper). By default it will use Active Record but you can change this by setting the +MODEL_ADAPTER+ environment variable before running. You can run the +bundle+ command with this as well to ensure you have the installed gems.
16
17 MODEL_ADAPTER=data_mapper bundle
18 MODEL_ADAPTER=data_mapper rake
19
20 The different model adapters you can specify are:
21
22 * active_record (default)
23 * data_mapper
24 * mongoid
6ccb4dd @ryanb adding spec_all rake task to spec readme
authored
25
26 You can also run the +spec_all+ rake task to run specs for each adapter.
27
28 rake spec_all
Something went wrong with that request. Please try again.