This repository has been archived by the owner on Dec 12, 2021. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adding map_additions module with spec
- Loading branch information
Ryan Bates
committed
Apr 3, 2008
1 parent
d0c9c47
commit cbdf225
Showing
3 changed files
with
23 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
$:.unshift(File.dirname(__FILE__)) | ||
# require 'static_actions/foo' | ||
require 'static_actions/map_additions' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
module StaticActions | ||
module MapAdditions | ||
def static_actions | ||
|
||
end | ||
end | ||
end | ||
|
||
class ActionController::Routing::RouteSet::Mapper | ||
include StaticActions::MapAdditions | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
require File.dirname(__FILE__) + '/../spec_helper' | ||
|
||
describe StaticActions::MapAdditions do | ||
before(:each) do | ||
@map = ActionController::Routing::RouteSet::Mapper.new(ActionController::Routing::RouteSet.new) | ||
end | ||
|
||
it "should respond to static_actions" do | ||
@map.should respond_to(:static_actions) | ||
end | ||
end |