Moved Correlation Dashboard script
This commit is contained in:
6
index.js
6
index.js
@@ -4,7 +4,7 @@ import exactLandingPage from './tests/exactLandingPage.js';
|
||||
//import ExACT_login from './tests/ExACT_login.js';
|
||||
|
||||
//DASHBOARDS
|
||||
import correlationsDashboard from './tests/correlationsDashboard.js';
|
||||
import correlationDashboard from './tests/CorrelationDashboard/correlationDashboard.js';
|
||||
|
||||
import ExACT_dashboardMyContent from './tests/ExACT_dashboardMyContent.js';
|
||||
import ExACT_dashboardSemanticStandardsComparison from './tests/ExACT_dashboardSemanticStandardsComparison.js';
|
||||
@@ -65,7 +65,7 @@ app.get('/', (req, res) => {
|
||||
<div style="padding:3px;"><strong><a href='/exactLandingPage' target='_blank'>ExACT Landing Page</a></strong></div>
|
||||
|
||||
<h1 style="text-align:center; color:#055a8c; font-size:20px; ">DASHBOARD</h1>
|
||||
<div style="padding:3px;"><strong><a href='/correlationsDashboard' target='_blank'>Correlations Dashboard</a></strong></div>
|
||||
<div style="padding:3px;"><strong><a href='/correlationDashboard' target='_blank'>Correlation Dashboard</a></strong></div>
|
||||
|
||||
<!-- NEEDS UPDATE
|
||||
<div style="padding:3px;"><strong><a href='/ExACT_dashboardMyContent' target='_blank'>My Content Widget</a></strong></div>
|
||||
@@ -129,7 +129,7 @@ app.get('/', (req, res) => {
|
||||
//app.get('/ExACT_login', ExACT_login);
|
||||
|
||||
//DASHBOARDS
|
||||
app.get('/correlationsDashboard', correlationsDashboard);
|
||||
app.get('/correlationDashboard', correlationDashboard);
|
||||
|
||||
//FRAMEWORKS
|
||||
app.get('/frameworkManagementPage', frameworkManagementPage);
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@@ -4,8 +4,8 @@ import fs from 'fs';
|
||||
import XLSX from 'xlsx';
|
||||
import path from 'path';
|
||||
|
||||
const correlationsDashboard = (req, res) => {
|
||||
res.send('<h2>ExACT Automated Test Script: Correlations Dashboard(correlationsDashboard) | Initiated</h2>');
|
||||
const correlationDashboard = (req, res) => {
|
||||
res.send('<h2>ExACT Automated Test Script: Correlation Dashboard(correlationDashboard) | Initiated</h2>');
|
||||
(async function example() {
|
||||
let driver = await new Builder()
|
||||
.forBrowser('chrome')
|
||||
@@ -1599,6 +1599,7 @@ const steps = [
|
||||
'Creating Org',
|
||||
'Demo Client Standards',
|
||||
'Demo Standards',
|
||||
'Imports',
|
||||
'New Folder',
|
||||
'QA Client Test Frameworks',
|
||||
'United States Standards',
|
||||
@@ -5541,7 +5542,7 @@ const logStep = (worksheet, stepDescription, status, stepIndex, timestamp, scree
|
||||
const takeScreenshot = async (driver, stepIndex, stepDescription) => {
|
||||
const screenshot = await driver.takeScreenshot();
|
||||
|
||||
const dir = path.join('screenshots', 'correlationsDashboard');
|
||||
const dir = path.join('screenshots', 'correlationDashboard');
|
||||
|
||||
const screenshotFileName = `step_${stepIndex}_${stepDescription.replace(/\s+/g, '_')}.png`;
|
||||
const screenshotPath = path.join(dir, screenshotFileName);
|
||||
@@ -5549,11 +5550,11 @@ const takeScreenshot = async (driver, stepIndex, stepDescription) => {
|
||||
return screenshotPath;
|
||||
};
|
||||
|
||||
const resultsFile = path.join('results', 'correlationsDashboard.xlsx');
|
||||
const resultsFile = path.join('results', 'correlationDashboard.xlsx');
|
||||
|
||||
const clearOldResults = () => {
|
||||
//Remove old screenshots
|
||||
const screenshotDir = path.join('screenshots', 'correlationsDashboard');
|
||||
const screenshotDir = path.join('screenshots', 'correlationDashboard');
|
||||
if (fs.existsSync(screenshotDir)) {
|
||||
fs.rmSync(screenshotDir, { recursive: true, force: true });
|
||||
}
|
||||
@@ -5563,7 +5564,7 @@ const clearOldResults = () => {
|
||||
if (fs.existsSync(resultsFile)) {
|
||||
fs.unlinkSync(resultsFile);
|
||||
}
|
||||
fs.mkdirSync('results', { recursive: true });
|
||||
fs.mkdirSync('results', { recursive: true });
|
||||
};
|
||||
|
||||
try {
|
||||
@@ -5629,11 +5630,11 @@ try {
|
||||
//Check if log out was successful
|
||||
if (allStepsPassed) {
|
||||
console.log('------------->| THE END |<-------------');
|
||||
console.log('PASSED: CORRELATIONS DASHBOARD(correlationsDashboard); All test steps completed successfully');
|
||||
console.log('PASSED: CORRELATION DASHBOARD(correlationDashboard); All test steps completed successfully');
|
||||
testStatus = 'Passed';
|
||||
} else {
|
||||
console.log('------------->| THE END |<-------------');
|
||||
console.log('FAILED: CORRELATIONS DASHBOARD(correlationsDashboard); One or more test steps failed');
|
||||
console.log('FAILED: CORRELATION DASHBOARD(correlationDashboard); One or more test steps failed');
|
||||
console.log('FAILED STEPS:');
|
||||
failedSteps.forEach(step => console.error(` ✗ ${step}`));
|
||||
testStatus = 'Failed';
|
||||
@@ -5652,4 +5653,4 @@ try {
|
||||
})();
|
||||
}
|
||||
|
||||
export default correlationsDashboard;
|
||||
export default correlationDashboard;
|
||||
Reference in New Issue
Block a user