Skip to content

Commit

Permalink
Fix eventing skr pipeline (#14515)
Browse files Browse the repository at this point in the history
* Fixed missing function parameter

* Fix global leaks detected:parsed error

* Fix lint errors
  • Loading branch information
raypinto authored Jun 8, 2022
1 parent e47dedb commit b051ee2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
3 changes: 1 addition & 2 deletions tests/fast-integration/compass/gql.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,7 @@ function deleteApplicationLabel(appID, key) {
}

function escapeForGQL(str) {
parsed = str.split('"').join(`\\\\\\"`);

const parsed = str.split('"').join(`\\\\\\"`);
return parsed.replace(/\\\\s/g, '\\\\\\\\\\\\\\\\s');
}

Expand Down
7 changes: 4 additions & 3 deletions tests/fast-integration/test/fixtures/commerce-mock/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ async function checkFunctionResponse(functionNamespace, mockNamespace = 'mocks')
const accessToken = await oAuthTokenGetter.getToken(['read', 'write']);

// expect no error when authorized
let res = await retryPromise(
const res = await retryPromise(
() => axios.post(`https://lastorder.${host}/function`, {orderCode: '789'}, {
timeout: 5000,
headers: {Authorization: `bearer ${accessToken}`},
Expand All @@ -139,7 +139,7 @@ async function checkFunctionResponse(functionNamespace, mockNamespace = 'mocks')
// expect error when unauthorized
let errorOccurred = false;
try {
res = await axios.post(`https://lastorder.${host}/function`, {orderCode: '789'}, {timeout: 5000});
await axios.post(`https://lastorder.${host}/function`, {orderCode: '789'}, {timeout: 5000});
} catch (err) {
errorOccurred = true;
expect(err.response.status).to.be.equal(401);
Expand Down Expand Up @@ -551,7 +551,8 @@ async function ensureCommerceMockWithCompassTestFixture(
appName,
scenarioName,
mockNamespace,
targetNamespace) {
targetNamespace,
compassScenarioAlreadyExist = false) {
const lastOrderFunction = prepareFunction('central-app-gateway-compass', `mp-${appName}`);

const mockHost = await provisionCommerceMockResources(
Expand Down

0 comments on commit b051ee2

Please sign in to comment.