Skip to content

Commit

Permalink
s
Browse files Browse the repository at this point in the history
  • Loading branch information
williamlardier committed Apr 15, 2024
1 parent 0bee8a0 commit 7d7d91e
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion config.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
},
"clusters": 1,
"log": {
"logLevel": "info",
"logLevel": "trace",
"dumpLevel": "error"
},
"healthChecks": {
Expand Down
7 changes: 6 additions & 1 deletion tests/functional/aws-node-sdk/test/quota/tooling.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
const fetch = require('node-fetch');
const AWS = require('aws-sdk');
const xml2js = require('xml2js');
const memCredentials = require('../../lib/json/mem_credentials.json');

const sendRequest = async (method, host, path, body = '') =>
new Promise(async (resolve, reject) => {
Expand All @@ -18,7 +19,11 @@ const sendRequest = async (method, host, path, body = '') =>
request.region = 'us-east-1';

const signer = new AWS.Signers.V4(request, service);
signer.addAuthorization(AWS.config.credentials, new Date());
const _memCredentials = memCredentials.default;
const accessKeyId = AWS.config.credentials?.accessKeyId || _memCredentials.accessKey;
const secretAccessKey = AWS.config.credentials?.secretAccessKey || _memCredentials.secretKey;
const credentials = new AWS.Credentials(accessKeyId, secretAccessKey);
signer.addAuthorization(credentials, new Date());

const url = `http://${host}${path}`;
const options = {
Expand Down
4 changes: 4 additions & 0 deletions tests/functional/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,9 @@
"localCache": {
"host": "127.0.0.1",
"port": 6379
},
"log": {
"logLevel": "trace",
"dumpLevel": "error"
}
}

0 comments on commit 7d7d91e

Please sign in to comment.