mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2026-01-08 03:57:31 +00:00
resolve e2e test error
This commit is contained in:
@@ -191,7 +191,7 @@
|
|||||||
"pack:fast": "node --max_old_space_size=10196 ./node_modules/webpack/bin/webpack.js --mode development --progress",
|
"pack:fast": "node --max_old_space_size=10196 ./node_modules/webpack/bin/webpack.js --mode development --progress",
|
||||||
"copyToConsumers": "node copyToConsumers",
|
"copyToConsumers": "node copyToConsumers",
|
||||||
"test": "rimraf coverage && jest",
|
"test": "rimraf coverage && jest",
|
||||||
"test:e2e": "jest -c ./jest.config.e2e.js --detectOpenHandles",
|
"test:e2e": "jest -c ./jest.config.playwright.js --detectOpenHandles",
|
||||||
"watch": "npm run start",
|
"watch": "npm run start",
|
||||||
"wait-for-server": "wait-on -t 240000 -i 5000 -v https-get://0.0.0.0:1234/",
|
"wait-for-server": "wait-on -t 240000 -i 5000 -v https-get://0.0.0.0:1234/",
|
||||||
"build:ase": "gulp build:ase",
|
"build:ase": "gulp build:ase",
|
||||||
|
|||||||
@@ -99,8 +99,8 @@ export function computeDisplayUsageString(usageInKB: number): string {
|
|||||||
usageInGB > 0.1
|
usageInGB > 0.1
|
||||||
? usageInGB.toFixed(2) + " GB"
|
? usageInGB.toFixed(2) + " GB"
|
||||||
: usageInMB > 0.1
|
: usageInMB > 0.1
|
||||||
? usageInMB.toFixed(2) + " MB"
|
? usageInMB.toFixed(2) + " MB"
|
||||||
: usageInKB.toFixed(2) + " KB";
|
: usageInKB.toFixed(2) + " KB";
|
||||||
return displayUsageString;
|
return displayUsageString;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -167,8 +167,9 @@ export function getAutoPilotV3SpendHtml(maxAutoPilotThroughputSet: number, isDat
|
|||||||
maxAutoPilotThroughputSet
|
maxAutoPilotThroughputSet
|
||||||
)} RU/s (10% of max RU/s) - ${maxAutoPilotThroughputSet} RU/s</b> based on usage. <br /><br />After the first ${AutoPilotUtils.getStorageBasedOnUserInput(
|
)} RU/s (10% of max RU/s) - ${maxAutoPilotThroughputSet} RU/s</b> based on usage. <br /><br />After the first ${AutoPilotUtils.getStorageBasedOnUserInput(
|
||||||
maxAutoPilotThroughputSet
|
maxAutoPilotThroughputSet
|
||||||
)} GB of data stored, the max RU/s will be automatically upgraded based on the new storage value. <a href='${Constants.AutopilotDocumentation.Url
|
)} GB of data stored, the max RU/s will be automatically upgraded based on the new storage value. <a href='${
|
||||||
}' target='_blank' aria-label='Learn more about autoscale throughput'>Learn more</a>.`;
|
Constants.AutopilotDocumentation.Url
|
||||||
|
}' target='_blank' aria-label='Learn more about autoscale throughput'>Learn more</a>.`;
|
||||||
}
|
}
|
||||||
|
|
||||||
export function getEstimatedAutoscaleSpendHtml(
|
export function getEstimatedAutoscaleSpendHtml(
|
||||||
@@ -195,7 +196,8 @@ export function getEstimatedAutoscaleSpendHtml(
|
|||||||
`Estimated monthly cost (${currency}): <b>` +
|
`Estimated monthly cost (${currency}): <b>` +
|
||||||
`${currencySign}${calculateEstimateNumber(monthlyPrice / 10)} - ` +
|
`${currencySign}${calculateEstimateNumber(monthlyPrice / 10)} - ` +
|
||||||
`${currencySign}${calculateEstimateNumber(monthlyPrice)} </b> ` +
|
`${currencySign}${calculateEstimateNumber(monthlyPrice)} </b> ` +
|
||||||
`(${regions} ${regions === 1 ? "region" : "regions"}, ${throughput / 10
|
`(${regions} ${regions === 1 ? "region" : "regions"}, ${
|
||||||
|
throughput / 10
|
||||||
} - ${throughput} RU/s, ${currencySign}${pricePerRu}/RU)`
|
} - ${throughput} RU/s, ${currencySign}${pricePerRu}/RU)`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -249,11 +251,11 @@ export function getEstimatedSpendAcknowledgeString(
|
|||||||
const currencySign: string = getCurrencySign(serverId);
|
const currencySign: string = getCurrencySign(serverId);
|
||||||
return !isAutoscale
|
return !isAutoscale
|
||||||
? `I acknowledge the estimated ${currencySign}${calculateEstimateNumber(
|
? `I acknowledge the estimated ${currencySign}${calculateEstimateNumber(
|
||||||
dailyPrice
|
dailyPrice
|
||||||
)} daily cost for the throughput above.`
|
)} daily cost for the throughput above.`
|
||||||
: `I acknowledge the estimated ${currencySign}${calculateEstimateNumber(
|
: `I acknowledge the estimated ${currencySign}${calculateEstimateNumber(
|
||||||
monthlyPrice / 10
|
monthlyPrice / 10
|
||||||
)} - ${currencySign}${calculateEstimateNumber(monthlyPrice)} monthly cost for the throughput above.`;
|
)} - ${currencySign}${calculateEstimateNumber(monthlyPrice)} monthly cost for the throughput above.`;
|
||||||
}
|
}
|
||||||
|
|
||||||
export function getUpsellMessage(
|
export function getUpsellMessage(
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ test("Notebooks", async () => {
|
|||||||
await explorer.click('[data-test="My Notebooks"] [aria-label="More"]');
|
await explorer.click('[data-test="My Notebooks"] [aria-label="More"]');
|
||||||
await explorer.click('button[role="menuitem"]:has-text("Upload File")');
|
await explorer.click('button[role="menuitem"]:has-text("Upload File")');
|
||||||
await explorer.setInputFiles("#importFileInput", path.join(__dirname, fileToUpload));
|
await explorer.setInputFiles("#importFileInput", path.join(__dirname, fileToUpload));
|
||||||
await explorer.click('[aria-label="Submit"]');
|
await explorer.click('[aria-label="Upload"]');
|
||||||
await explorer.click(`[data-test="${fileToUpload}"] [aria-label="More"]`);
|
await explorer.click(`[data-test="${fileToUpload}"] [aria-label="More"]`);
|
||||||
await explorer.click('button[role="menuitem"]:has-text("Delete")');
|
await explorer.click('button[role="menuitem"]:has-text("Delete")');
|
||||||
await explorer.click('button:has-text("Delete")');
|
await explorer.click('button:has-text("Delete")');
|
||||||
|
|||||||
Reference in New Issue
Block a user