Script Management
The
Script Management
module in AngusTester provides full lifecycle management for automated test scripts, supporting the entire process from script creation and debugging to execution and version control.
I. Basic Script Operations
1. Create Script
Description: Define automated testing or data simulation logic
Steps:
- In
Script Management
, click "Add Script" - Fill in key parameters:
- Naming format:
[Module]_[Function]_Script
(e.g., Login_PerformanceTest) - Script type (Test Script/Data Generation/Mock)
- Script content (written according to specifications)
⚠️ Refer to the official documentation for syntax standards
- Naming format:
2. Import Script
Description: Bulk import external script files
Steps:
- In
Script Management
, click "Import Script" - Process:
- Download template (JSON format)
- Fill content according to specifications
- Upload file (≤10MB)
❗ Select overwrite policy for duplicate script names
3. Modify Script
Description: Update script logic or configurations
Steps:
- In
Script Management List
, click "Edit" for the target script - Adjustable content:
- Script parameters (environment variable configurations)
- Core logic (must retain historical versions)
⚠️ Running scripts cannot be modified
4. Clone Script
Description: Create script copies for derivative development
Steps:
- On the
Script Details Page
, click "Clone" - The system automatically:
- Generates a copy (appends "_Copy" to the name)
- Copies parameter configurations
- Preserves content versions
Key parameters must be manually modified
5. Export Script
Description: Backup scripts or migrate across projects
Steps:
- In
Script Management List
, select target scripts - Click "Export"
- Select format:
- JSON (standard structure)
- YAML (compact format)
II. Script Execution Management
1. Debug Script
Description: Verify script logic correctness
Steps:
- On the
Script Details Page
, click "Debug" - Analyze debug results:
- Output logs (segmented by execution steps)
- Error stack traces (highlighted in red)
- Variable tracking (real-time value display)
⚠️ Debug environment is isolated from production
2. Execute Script
Description: Run script tasks officially
Steps:
- In
Script Management List
, click "Execute" for the target script - Select execution mode:
- Immediate execution (single run)
- Scheduled execution (set cron expression)
- Monitor execution status:
- Real-time log output
- Resource consumption charts
- Abnormal interruption notifications
❗ Maximum runtime per script: 2 hours
3. Terminate Execution
Description: Force-stop abnormal scripts
Steps:
- In
Execution Record List
, locate the running task - Click "Terminate"
- The system automatically:
- Sends SIGTERM signal
- Saves current progress snapshot
- Generates exception analysis report
⚠️ May cause data state inconsistency
4. Execution Record Audit
Description: Trace historical execution details
Steps:
- In
Execution Records
, click the target record - View key information:
- Input/Output parameter snapshots
- Execution timeline (including subprocess tree)
- Resource usage heatmap
Data retained for 90 days
III. Script Maintenance Management
1. Delete Script
Description: Clean up obsolete script resources
Steps:
- In
Script Management List
, select target scripts - Click "Delete"
- Confirm by entering the script name
❗ Scripts bound to tasks must be unlinked first
2. Version Rollback
Description: Restore stable historical versions
Steps:
- Navigate to
Script Details → Version History
- Select target version and click "Restore"
- The system automatically:
- Overwrites current content
- Generates rollback record
- Triggers email notification
⚠️ Only the last 10 versions are retained