Sha256: 76e456838a0000a91b2387a791280135cca84fd7cfaedc3b65cbbaca29a9a6e7

Contents?: true

Size: 796 Bytes

Versions: 26

Compression:

Stored size: 796 Bytes

Contents

require File.dirname(__FILE__) + '/../../test_helper'
require 'cms/products_controller'

# Re-raise errors caught by the controller.
class Cms::ProductsController; def rescue_action(e) raise e end; end

class Cms::ProductsControllerTest < ActionController::TestCase
  def setup
    @controller = Cms::ProductsController.new
    @request    = ActionController::TestRequest.new
    @response   = ActionController::TestResponse.new
    @product    = Product.find 1
  end

  should_be_restful do |resource|
    resource.formats = [:html]
    resource.klass   = ::Product
    resource.update.redirect  = 'cms_product_path(@product)'
    resource.destroy.redirect = 'cms_products_path'
    resource.create.redirect  = 'cms_product_path(@product)'
    resource.create.flash     = /something/i
  end
end

Version data entries

26 entries across 26 versions & 12 rubygems

Version Path
csmosx-resource_controller-0.6.6 test/test/functional/cms/products_controller_test.rb
csmosx-resource_controller-0.6.7 test/test/functional/cms/products_controller_test.rb
dkubb-resource_controller-0.6.5 test/test/functional/cms/products_controller_test.rb
giraffesoft-resource_controller-0.5.5 test/test/functional/cms/products_controller_test.rb
giraffesoft-resource_controller-0.5.6 test/test/functional/cms/products_controller_test.rb
giraffesoft-resource_controller-0.6.0 test/test/functional/cms/products_controller_test.rb
giraffesoft-resource_controller-0.6.1 test/test/functional/cms/products_controller_test.rb
giraffesoft-resource_controller-0.6.5 test/test/functional/cms/products_controller_test.rb
jeffrafter-resource_controller-0.5.5 test/test/functional/cms/products_controller_test.rb
maser-resource_controller-0.6.6 test/test/functional/cms/products_controller_test.rb
radar-resource_controller-0.6.6 test/test/functional/cms/products_controller_test.rb
strikeroff-resource_controller-0.6.6 test/test/functional/cms/products_controller_test.rb
viva-resource_controller-0.6.5.1 test/test/functional/cms/products_controller_test.rb
viva-resource_controller-0.6.5.2 test/test/functional/cms/products_controller_test.rb
viva-resource_controller-0.6.5 test/test/functional/cms/products_controller_test.rb
matid-resource_controller-0.7.2 test/test/functional/cms/products_controller_test.rb
matid-resource_controller-0.7.1 test/test/functional/cms/products_controller_test.rb
matid-resource_controller-0.7.0 test/test/functional/cms/products_controller_test.rb
resource_controller_views-0.6.6.views2 test/test/functional/cms/products_controller_test.rb
matid-resource_controller-0.6.7 test/test/functional/cms/products_controller_test.rb