diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2005-02-18 23:43:09 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2005-02-18 23:43:09 +0000 |
commit | 7a67d0f617db7d2962b6c3b80466e21570b244bf (patch) | |
tree | 56fa640e31f4f7f22d34a246bc1b197706a07e3a /actionservice/test/container_test.rb | |
parent | fdecb6843ba8c5b0f718225f343017e11fa7f711 (diff) | |
download | rails-7a67d0f617db7d2962b6c3b80466e21570b244bf.tar.gz rails-7a67d0f617db7d2962b6c3b80466e21570b244bf.tar.bz2 rails-7a67d0f617db7d2962b6c3b80466e21570b244bf.zip |
Renamed Action Service to Action Web Service
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@669 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionservice/test/container_test.rb')
-rw-r--r-- | actionservice/test/container_test.rb | 53 |
1 files changed, 0 insertions, 53 deletions
diff --git a/actionservice/test/container_test.rb b/actionservice/test/container_test.rb deleted file mode 100644 index 8c66651b64..0000000000 --- a/actionservice/test/container_test.rb +++ /dev/null @@ -1,53 +0,0 @@ -require File.dirname(__FILE__) + '/abstract_unit' - -module ContainerTest - - $immediate_service = Object.new - $deferred_service = Object.new - - class DelegateContainer < ActionController::Base - web_service_dispatching_mode :delegated - - attr :flag - attr :previous_flag - - def initialize - @previous_flag = nil - @flag = true - end - - web_service :immediate_service, $immediate_service - web_service(:deferred_service) { @previous_flag = @flag; @flag = false; $deferred_service } - end - - class DirectContainer < ActionController::Base - web_service_dispatching_mode :direct - end -end - -class TC_Container < Test::Unit::TestCase - def setup - @delegate_container = ContainerTest::DelegateContainer.new - @direct_container = ContainerTest::DirectContainer.new - end - - def test_registration - assert(ContainerTest::DelegateContainer.has_web_service?(:immediate_service)) - assert(ContainerTest::DelegateContainer.has_web_service?(:deferred_service)) - assert(!ContainerTest::DelegateContainer.has_web_service?(:fake_service)) - end - - def test_service_object - assert(@delegate_container.flag == true) - assert(@delegate_container.web_service_object(:immediate_service) == $immediate_service) - assert(@delegate_container.previous_flag.nil?) - assert(@delegate_container.flag == true) - assert(@delegate_container.web_service_object(:deferred_service) == $deferred_service) - assert(@delegate_container.previous_flag == true) - assert(@delegate_container.flag == false) - end - - def test_direct_container - assert(ContainerTest::DirectContainer.web_service_dispatching_mode == :direct) - end -end |