Skip to content

Commit

Permalink
update getEndpointSuffix for eu-isoe-west-1 (#4657)
Browse files Browse the repository at this point in the history
  • Loading branch information
kuhe committed Jul 8, 2024
1 parent ddd3a96 commit 2074ef1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/region_config.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,8 @@ function getEndpointSuffix(region) {
'^cn\\-\\w+\\-\\d+$': 'amazonaws.com.cn',
'^us\\-gov\\-\\w+\\-\\d+$': 'amazonaws.com',
'^us\\-iso\\-\\w+\\-\\d+$': 'c2s.ic.gov',
'^us\\-isob\\-\\w+\\-\\d+$': 'sc2s.sgov.gov'
'^us\\-isob\\-\\w+\\-\\d+$': 'sc2s.sgov.gov',
'^eu\\-isoe\\-west\\-1$': 'cloud.adc-e.uk',
};
var defaultSuffix = 'amazonaws.com';
var regexes = Object.keys(regionRegexes);
Expand Down
5 changes: 5 additions & 0 deletions test/region_config.spec.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
const helpers = require('./helpers');
const AWS = helpers.AWS;
const MockService = helpers.MockService;
var getEndpointSuffix = require('../lib/region_config').getEndpointSuffix;

describe('region_config.js', function() {
it('sets endpoint configuration option for default regions', function() {
Expand Down Expand Up @@ -134,6 +135,10 @@ describe('region_config.js', function() {
expect(service.isGlobalEndpoint).to.equal(false);
expect(service.endpoint.host).to.equal('sts.us-gov-west-1.amazonaws.com');
});

it('resolves the endpoint suffix for eu-isoe-west-1', function() {
expect(getEndpointSuffix('eu-isoe-west-1')).to.equal('cloud.adc-e.uk');
});
});

describe('region_config_data.json', function() {
Expand Down

0 comments on commit 2074ef1

Please sign in to comment.