diff options
Diffstat (limited to 'spec/functions/capitalize_spec.rb')
-rwxr-xr-x | spec/functions/capitalize_spec.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/spec/functions/capitalize_spec.rb b/spec/functions/capitalize_spec.rb index 0cc2d76..fd0e92b 100755 --- a/spec/functions/capitalize_spec.rb +++ b/spec/functions/capitalize_spec.rb @@ -16,4 +16,13 @@ describe "the capitalize function" do result = scope.function_capitalize(["abc"]) expect(result).to(eq("Abc")) end + + it "should accept objects which extend String" do + class AlsoString < String + end + + value = AlsoString.new('abc') + result = scope.function_capitalize([value]) + result.should(eq('Abc')) + end end |