Changesets can be listed by changeset number.
The Git repository is here.
- Revision:
- 373
- Log:
Initial import of Radiant 0.9.1, which is now packaged as a gem. This is an
import of the tagged 0.9.1 source checked out from GitHub, which isn't quite
the same as the gem distribution - but it doesn't seem to be available in an
archived form and the installed gem already has modifications, so this is
the closest I can get.
- Author:
- rool
- Date:
- Mon Mar 21 13:40:05 +0000 2011
- Size:
- 1055 Bytes
1 | require File.dirname(__FILE__) + '/../spec_helper' |
2 | |
3 | describe TextFilter do |
4 | class ReverseFilter < TextFilter |
5 | description %{Reverses text.} |
6 | def filter(text) |
7 | text.reverse |
8 | end |
9 | end |
10 | |
11 | class CustomFilter < TextFilter |
12 | filter_name "Really Custom" |
13 | description_file File.dirname(__FILE__) + "/../fixtures/sample.txt" |
14 | end |
15 | |
16 | it 'should allow description annotation' do |
17 | ReverseFilter.description.should == %{Reverses text.} |
18 | end |
19 | |
20 | it 'should description_file annotation' do |
21 | CustomFilter.description.should == File.read(File.dirname(__FILE__) + "/../fixtures/sample.txt") |
22 | end |
23 | |
24 | it 'should filter text with base filter' do |
25 | filter = TextFilter.new |
26 | filter.filter('test').should == 'test' |
27 | end |
28 | |
29 | it 'should filter text with subclass' do |
30 | ReverseFilter.filter('test').should == 'tset' |
31 | end |
32 | |
33 | it 'should allow filter_name annotation' do |
34 | CustomFilter.filter_name.should == 'Really Custom' |
35 | end |
36 | |
37 | it 'should default filter_name annotation' do |
38 | ReverseFilter.filter_name.should == 'Reverse' |
39 | end |
40 | end |