diff --git a/index.js b/index.js
index 2c3bf4c..15c016b 100644
--- a/index.js
+++ b/index.js
@@ -68,6 +68,7 @@ app.get('/', (req, res) => {
DASHBOARD
+
| NEXT ACTION: Selected Include Related Standards: Washington, Common Core State Standards, California Mathematics 1997');
//Click away to close dropdown using executeScript to bypass interception
@@ -2651,6 +2651,8 @@ const takeScreenshot = async (driver, stepIndex, stepDescription) => {
return screenshotPath;
};
+const resultsFile = path.join('results', 'myStandardsSearchRelatedStandards.xlsx');
+
const clearOldResults = () => {
//Remove old screenshots
const screenshotDir = path.join('screenshots', 'myStandardsSearchRelatedStandardsResults');
@@ -2660,9 +2662,10 @@ const clearOldResults = () => {
fs.mkdirSync(screenshotDir, { recursive: true });
//Remove old Excel file
- if (fs.existsSync('myStandardsSearchRelatedStandardsResults.xlsx')) {
- fs.unlinkSync('myStandardsSearchRelatedStandardsResults.xlsx');
+ if (fs.existsSync(resultsFile)) {
+ fs.unlinkSync(resultsFile);
}
+ fs.mkdirSync('results', { recursive: true });
};
try {
@@ -2739,7 +2742,7 @@ try {
//Write the updated worksheet back to the workbook and save it
workbook.Sheets['Sheet1'] = worksheet;
- XLSX.writeFile(workbook, 'myStandardsSearchRelatedStandardsResults.xlsx');
+ XLSX.writeFile(workbook, resultsFile);
} finally {
await driver.quit();
}