Sha256: 98def966ae25a1932dcb11c2ee468d3170a95774a4dce4d0d1730bfeb95e1865

Contents?: true

Size: 499 Bytes

Versions: 13

Compression:

Stored size: 499 Bytes

Contents

# For tests only - uses custom 'update' implementation which passes a block to
# Scimitar::ActiveRecordBackedResourcesController#create.
#
class CustomUpdateMockUsersController < Scimitar::ActiveRecordBackedResourcesController

  OVERRIDDEN_NAME = SecureRandom.uuid

  def update
    super do | resource |
      resource.first_name = OVERRIDDEN_NAME
      resource.save!
    end
  end

  protected

    def storage_class
      MockUser
    end

    def storage_scope
      MockUser.all
    end

end

Version data entries

13 entries across 13 versions & 2 rubygems

Version Path
scimitar-1.11.0 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb
scimitar-2.10.0 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb
scimitar-1.10.0 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb
scimitar-2.9.0 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb
scimitar-2.8.0 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb
scimitar-2.7.3 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb
powerhome-scimitar-1.0.0 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb
scimitar-2.7.2 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb
scimitar-1.8.2 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb
scimitar-1.8.1 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb
scimitar-2.7.1 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb
scimitar-1.8.0 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb
scimitar-2.7.0 spec/apps/dummy/app/controllers/custom_update_mock_users_controller.rb