Please enable JavaScript.
Coggle requires JavaScript to display documents.
Script Upload Flow - Current Behavior - Coggle Diagram
Script Upload Flow - Current Behavior
Dashboard UI
client/src/pages/Dashboard.jsx
Responsibilities
Accepts .py and .ps1 files
Stores runnerScriptName only
Does NOT read runner script content
Shows Upload Runner Script button
Validates file extension
Imports
Exports
Temporary Run Draft
sessionStorage
Stores
runnerScriptName
configFileName
configContent
testName
What needs to change
no runnerScriptContent :
no actual .ps1/.py file body
Imports
Exports
Confirmation Page
client/src/pages/Confirmation.jsx
Reads run draft from route state or sessionStorage
Displays runner script name
Sends run request to backend
Still only sends runnerScriptName, not file content
Exports
Imports
API Helper
client/src/lib/api.js
POST payload to /api/runs/start
Does not care what payload contains
Imports
Exports
startTestRun()
startWindowsVm()
getWindowsVmStatus()
Backend Run Start
server/index.js
Receives POST /api/runs/start
Passes req.body into createRunRecord()
Starts or reuses Windows VM
Imports
createRunRecord()
Starts the backend
Run Store
server/lib/runStore.js
Creates isolated run folder
Writes meta.json
Writes task.json
Current hardcoded behavior:
taskType defaults to notepad_lifecycle
payload defaults to buildDefaultTaskPayload()
Imports
Exports
readRun()
attachContainerId()
markRunLaunchFailure()
resolveRunFilePath()
Windows Guest Agent
WindowsVm/shared/DockVisionAgent.ps1
Reads active/current-run.json
Reads runs/{runId}/task.json
Switches on taskType
For notepad_lifecycle, runs built-in Notepad automation
Imports
Exports
Running Test Page
client/src/pages/running-test/TestPage.jsx
Polls GET /api/runs/{runId}
Displays status, logs, screenshots, artifacts
Imports
Exports