Skip to content

Commit f8aca7d

Browse files
Jeff DutilJeff Dutil
authored andcommitted
Spec fixes and update Aws namespace in comments.
1 parent 594281b commit f8aca7d

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

lib/aws/session_store/dynamo_db/configuration.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ class Configuration
153153
# See AWS DynamoDB documentation for table write_capacity for more
154154
# information on this setting.
155155
# @option options [DynamoDB Client] :dynamo_db_client
156-
# (AWS::DynamoDB::ClientV2) DynamoDB client used to perform database
156+
# (Aws::DynamoDB::ClientV2) DynamoDB client used to perform database
157157
# operations inside of middleware application.
158158
# @option options [Boolean] :raise_errors (false) If true, all errors are
159159
# raised up the stack when default ErrorHandler. If false, Only specified

lib/aws/session_store/dynamo_db/errors/base_handler.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,11 @@ class BaseHandler
3333
# error up the stack.
3434
# You may reraise the error passed.
3535
#
36-
# @param [AWS::DynamoDB::Errors::Base] error error passed in from
36+
# @param [Aws::DynamoDB::Errors::Base] error error passed in from
3737
# AWS::SessionStore::DynamoDB::RackMiddleware.
3838
# @param [Rack::Request::Environment,nil] env Rack environment
3939
# @return [false] If exception was handled and will not reraise exception.
40-
# @raise [AWS::DynamoDB::Errors] If error has be reraised.
40+
# @raise [Aws::DynamoDB::Errors] If error has be reraised.
4141
def handle_error(error, env = {})
4242
raise NotImplementedError
4343
end

lib/aws/session_store/dynamo_db/rack_middleware.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ class RackMiddleware < Rack::Session::Abstract::ID
2424
#
2525
# @param app Rack application.
2626
# @option (see Configuration#initialize)
27-
# @raise [AWS::DynamoDB::Errors::ResourceNotFoundException] If valid table
27+
# @raise [Aws::DynamoDB::Errors::ResourceNotFoundException] If valid table
2828
# name is not provided.
2929
# @raise [AWS::SessionStore::DynamoDB::MissingSecretKey] If secret key is
3030
# not provided.
@@ -51,7 +51,7 @@ def set_locking_strategy
5151
# Determines if the correct session table name is being used for
5252
# this application. Also tests existence of secret key.
5353
#
54-
# @raise [AWS::DynamoDB::Errors::ResourceNotFoundException] If wrong table
54+
# @raise [Aws::DynamoDB::Errors::ResourceNotFoundException] If wrong table
5555
# name.
5656
def validate_config
5757
raise MissingSecretKeyError unless @config.secret_key

spec/spec_helper.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,10 @@ def call(env)
3939

4040
ConstantHelpers = lambda do
4141
let(:token_error_msg) { 'The security token included in the request is invalid' }
42-
let(:resource_error) { Aws::DynamoDB::Errors::ResourceNotFoundException }
43-
let(:key_error) { Aws::DynamoDB::Errors::ValidationException.new(key_error_msg) }
42+
let(:resource_error) { Aws::DynamoDB::Errors::ResourceNotFoundException.new(double('Seahorse::Client::RequestContext'), 'Resource not found.') }
43+
let(:key_error) { Aws::DynamoDB::Errors::ValidationException.new(double('Seahorse::Client::RequestContext'), key_error_msg) }
4444
let(:key_error_msg) { 'The provided key element does not match the schema' }
45-
let(:client_error) { Aws::DynamoDB::Errors::UnrecognizedClientException }
45+
let(:client_error) { Aws::DynamoDB::Errors::UnrecognizedClientException.new(double('Seahorse::Client::RequestContext'), 'Unrecognized Client.') }
4646
let(:invalid_cookie) { {"HTTP_COOKIE" => "rack.session=ApplePieBlueberries"} }
4747
let(:invalid_session_data) { {"rack.session"=>{"multiplier" => 1}} }
4848
let(:rack_default_error_msg) { "Warning! AWS::SessionStore::DynamoDB failed to save session. Content dropped.\n" }

0 commit comments

Comments
 (0)