Add logging to debug QA automation failure.
Add logging to debug QA automation failure. Kishan reports about 1 out of 10 requests to this endpoint fail running qa regression.
This commit is contained in:
parent
83950834fe
commit
bba652cd1a
5 changed files with 25 additions and 4 deletions
|
|
@ -102,6 +102,8 @@ const storeActions = {
|
|||
RESET_SUBMITTED_ORDER: "resetSubmittedOrder",
|
||||
RESET_EXTERNAL_PARAMETER_STATE: "resetExternalParameterState",
|
||||
UPDATE_EXTERNAL_PARAMETER_MMS: "updateExternalParameterMMS",
|
||||
|
||||
SAVE_LOGGING_OPTION: "saveLoggingOption",
|
||||
};
|
||||
|
||||
export { storeActions };
|
||||
|
|
|
|||
|
|
@ -84,6 +84,7 @@ const storeMutations = {
|
|||
UPDATE_STATE_WITH_ORDER_INFORMATION: "updateStateWithOrderInformation",
|
||||
UPDATE_SAVE_SESSION_PROMISE: "updateSaveSessionPromise",
|
||||
UPDATE_LAST_PAGE_VISITED: "updateLastPageVisited",
|
||||
UPDATE_LOGGING_OPTION: "updateLoggingOption",
|
||||
|
||||
// EXPERIMENT MUTATIONS
|
||||
UPDATE_EXPERIMENTS: "updateExperiments",
|
||||
|
|
|
|||
|
|
@ -47,15 +47,16 @@
|
|||
v-bind:isDismissible="false" />
|
||||
</div>
|
||||
|
||||
<div v-if="isRecalibrationOnOrder && shouldHideRecalibration" class="questions-about-service my-5">
|
||||
<div
|
||||
v-if="isRecalibrationOnOrder && shouldHideRecalibration"
|
||||
class="questions-about-service my-5">
|
||||
<textBlock
|
||||
cmsWidgetName="QuestionsAboutYourServiceWidget"
|
||||
justifyText="left"
|
||||
class="service-questions" />
|
||||
<textBlock cmsWidgetName="CallOrTextWidget" justifyText="left" />
|
||||
<hr class="my-5" />
|
||||
<div
|
||||
class="d-flex flex-row checkbox-group">
|
||||
<div class="d-flex flex-row checkbox-group">
|
||||
<checkboxQuestion
|
||||
cmsWidgetName="RecalConfirmWidget"
|
||||
class="mb-5"
|
||||
|
|
|
|||
|
|
@ -460,6 +460,7 @@ async function navigate(
|
|||
const promo = getQuerystringParameter(queryStrings.PROMO);
|
||||
const pageError = getQuerystringParameter(queryStrings.PAGE_ERROR);
|
||||
const logQs = getQuerystringParameter(queryStrings.LOG);
|
||||
baseMixin.methods.dispatchStoreAction(storeActions.SAVE_LOGGING_OPTION, logQs, false);
|
||||
|
||||
log("------------- router index.js navigate start -----------------");
|
||||
log(" --scenario: ", scenario);
|
||||
|
|
|
|||
|
|
@ -184,6 +184,7 @@ const getDefaultState = () => {
|
|||
experiments: [],
|
||||
triggeredSiteEntry: false,
|
||||
affiliateCookies: [],
|
||||
loggingOption: false,
|
||||
},
|
||||
};
|
||||
};
|
||||
|
|
@ -414,6 +415,9 @@ export const mutations = {
|
|||
updateLastPageVisited(state, lastPageVisited) {
|
||||
state.applicationUser.lastPageVisited = lastPageVisited;
|
||||
},
|
||||
updateLoggingOption(state, loggingOption) {
|
||||
state.applicationUser.loggingOption = loggingOption;
|
||||
},
|
||||
// EVENT BUS MUTATIONS
|
||||
addEventToBus(state, event) {
|
||||
state.applicationUser.eventBus.push(event);
|
||||
|
|
@ -689,7 +693,9 @@ export const mutations = {
|
|||
!sessionInformation.order.payment.isInsurance &&
|
||||
!sessionInformation.order.serviceLocation.provider?.providerNumber
|
||||
) {
|
||||
console.log("------------- updateStateWithOrderInformation reset isInsurance -----------------");
|
||||
console.log(
|
||||
"------------- updateStateWithOrderInformation reset isInsurance -----------------"
|
||||
);
|
||||
console.log(new Date() + " sessionInformation: " + JSON.stringify(sessionInformation));
|
||||
state.order.payment.isInsurance = null;
|
||||
} else {
|
||||
|
|
@ -1031,6 +1037,7 @@ export const actions = {
|
|||
endpoint: endpoints.LookupVehicleByVin.url,
|
||||
payload: {
|
||||
vin: vin, // EX "1J4GW58S4XC541166"
|
||||
logEnabled: context.getters.applicationUser.loggingOption,
|
||||
},
|
||||
logApiCall: true,
|
||||
pageNameToLog: pageNameToLog,
|
||||
|
|
@ -3016,6 +3023,15 @@ export const actions = {
|
|||
);
|
||||
},
|
||||
|
||||
saveLoggingOption(context, loggingOption) {
|
||||
var option = false;
|
||||
if (loggingOption != null) {
|
||||
option = loggingOption == "true" ? true : false;
|
||||
}
|
||||
|
||||
context.commit(storeMutations.UPDATE_LOGGING_OPTION, option);
|
||||
},
|
||||
|
||||
async getRecalPartsAndSaveToLineItems(context, { pageNameToLog }) {
|
||||
// identify each part that needs recal
|
||||
const glassParts = context.state.order?.lineItems?.glassParts
|
||||
|
|
|
|||
Loading…
Reference in a new issue