Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
DC-TOM
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
刘照晖
DC-TOM
Commits
42622572
Commit
42622572
authored
Sep 12, 2025
by
Cai Wei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat(*): 测试脚本兼容
parent
f5b3ce1c
Pipeline
#1339
failed
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
53 additions
and
14 deletions
+53
-14
DC-TOM告警总览.cy.js
cypress/e2e/DC-TOM告警总览.cy.js
+10
-2
DC-TOM我的闭环.cy.js
cypress/e2e/DC-TOM我的闭环.cy.js
+21
-6
DC-TOM设备管理.cy.js
cypress/e2e/DC-TOM设备管理.cy.js
+9
-2
DC-TOM除尘器总览.cy.js
cypress/e2e/DC-TOM除尘器总览.cy.js
+13
-4
No files found.
cypress/e2e/DC-TOM告警总览.cy.js
View file @
42622572
...
...
@@ -39,8 +39,15 @@ describe('template spec', () => {
cy
.
get
(
'[data-testid="suspend-flag-radio-during"] > .el-radio__input > .el-radio__original'
).
check
();
cy
.
get
(
'[data-testid="suspend-flag-radio-all"] > .el-radio__label'
).
click
();
cy
.
get
(
'[data-testid="suspend-flag-radio-all"] > .el-radio__input > .el-radio__original'
).
check
();
cy
.
get
(
'[data-testid="cell-0-operate"] > [data-testid="suspend-action-link"]'
).
click
();
cy
.
get
(
'.el-dialog__headerbtn > .el-icon > svg'
).
click
();
// 添加兼容性检查,判断是否存在suspend-action-link元素
cy
.
get
(
'body'
).
then
(
$body
=>
{
// 检查是否存在suspend-action-link元素
if
(
$body
.
find
(
'[data-testid="cell-0-operate"] > [data-testid="suspend-action-link"]'
).
length
)
{
cy
.
get
(
'[data-testid="cell-0-operate"] > [data-testid="suspend-action-link"]'
).
click
();
cy
.
get
(
'.el-dialog__headerbtn > .el-icon > svg'
).
click
();
}
});
/* ==== End Cypress Studio ==== */
});
})
\ No newline at end of file
cypress/e2e/DC-TOM我的闭环.cy.js
View file @
42622572
...
...
@@ -33,12 +33,27 @@ describe('template spec', () => {
cy
.
get
(
'#device-type-option-2'
).
click
();
cy
.
get
(
'[data-testid="my-agency-search-button"] > span'
).
click
();
cy
.
get
(
'[data-testid="my-agency-reset-button"]'
).
click
();
cy
.
get
(
'[data-testid="cell-0-operation"] > [data-testid="my-agency-process-button"]'
).
click
();
cy
.
get
(
'.el-dialog__headerbtn > .el-icon > svg'
).
click
();
cy
.
get
(
'[data-testid="cell-0-operation"] > [data-testid="my-agency-dispatch-button"]'
).
click
();
cy
.
get
(
'[data-testid="assign-dialog"] > .el-dialog__header > .el-dialog__headerbtn > .el-icon > svg > path'
).
click
();
cy
.
get
(
'[data-testid="cell-0-operation"] > [data-testid="my-agency-change-bag-button"]'
).
click
();
cy
.
get
(
'[data-testid="bag-dialog"] > .el-dialog__header > .el-dialog__headerbtn > .el-icon > svg'
).
click
();
// 添加兼容性检查,判断是否存在操作按钮元素
cy
.
get
(
'body'
).
then
(
$body
=>
{
// 处理流程按钮
if
(
$body
.
find
(
'[data-testid="cell-0-operation"] > [data-testid="my-agency-process-button"]'
).
length
)
{
cy
.
get
(
'[data-testid="cell-0-operation"] > [data-testid="my-agency-process-button"]'
).
click
();
cy
.
get
(
'.el-dialog__headerbtn > .el-icon > svg'
).
click
();
}
// 处理派单按钮
if
(
$body
.
find
(
'[data-testid="cell-0-operation"] > [data-testid="my-agency-dispatch-button"]'
).
length
)
{
cy
.
get
(
'[data-testid="cell-0-operation"] > [data-testid="my-agency-dispatch-button"]'
).
click
();
cy
.
get
(
'[data-testid="assign-dialog"] > .el-dialog__header > .el-dialog__headerbtn > .el-icon > svg > path'
).
click
();
}
// 处理换袋按钮
if
(
$body
.
find
(
'[data-testid="cell-0-operation"] > [data-testid="my-agency-change-bag-button"]'
).
length
)
{
cy
.
get
(
'[data-testid="cell-0-operation"] > [data-testid="my-agency-change-bag-button"]'
).
click
();
cy
.
get
(
'[data-testid="bag-dialog"] > .el-dialog__header > .el-dialog__headerbtn > .el-icon > svg'
).
click
();
}
});
cy
.
get
(
'[data-testid="menu-item-my-loop/myDone"] > span'
).
click
();
cy
.
get
(
'[data-testid="event-name-input"]'
).
clear
(
't'
);
cy
.
get
(
'[data-testid="event-name-input"]'
).
type
(
'提升阀'
);
...
...
cypress/e2e/DC-TOM设备管理.cy.js
View file @
42622572
...
...
@@ -30,8 +30,15 @@ describe('template spec', () => {
cy
.
get
(
'#equipment-device-type-option-2'
).
click
();
cy
.
get
(
'[data-testid="equipment-search-button"] > span'
).
click
();
cy
.
get
(
'[data-testid="equipment-reset-button"] > span'
).
click
();
cy
.
get
(
'[data-testid="cell-0-operation"] > [data-testid="equipment-params-button"] > span'
).
click
();
cy
.
get
(
'[data-testid="confirm-button"]'
).
click
();
// 添加兼容性检查,判断是否存在设备参数按钮
cy
.
get
(
'body'
).
then
(
$body
=>
{
// 检查原始选择器
if
(
$body
.
find
(
'[data-testid="cell-0-operation"] > [data-testid="equipment-params-button"] > span'
).
length
)
{
cy
.
get
(
'[data-testid="cell-0-operation"] > [data-testid="equipment-params-button"] > span'
).
click
();
cy
.
get
(
'[data-testid="confirm-button"]'
).
click
();
}
});
cy
.
get
(
'[data-testid="menu-item-management/suspend-management"] > span'
).
click
();
cy
.
get
(
'[data-testid="project-select"] > .el-select__wrapper > .el-select__selection > .el-select__placeholder'
).
click
();
cy
.
get
(
'#project-option-0'
).
click
();
...
...
cypress/e2e/DC-TOM除尘器总览.cy.js
View file @
42622572
...
...
@@ -29,10 +29,18 @@ describe('template spec', () => {
cy
.
get
(
'[data-testid="save-button"] > span'
).
click
();
cy
.
get
(
'.status-matrix > :nth-child(1) > :nth-child(1)'
).
click
();
cy
.
get
(
'[data-testid="menu-item-dust-overview"] > span'
).
click
();
cy
.
get
(
'[data-testid="cell-0-operation"] > [data-testid="dust-view-button"]'
).
click
();
cy
.
get
(
'[data-testid="menu-item-dust-overview"] > span'
).
click
();
cy
.
get
(
'[data-testid="cell-0-operation"] > [data-testid="dust-edit-button"]'
).
click
();
cy
.
get
(
'[data-testid="confirm-button"]'
).
click
();
// 添加兼容性检查,判断是否存在操作按钮元素
cy
.
get
(
'body'
).
then
(
$body
=>
{
if
(
$body
.
find
(
'[data-testid="cell-0-operation"] > [data-testid="dust-view-button"]'
).
length
)
{
cy
.
get
(
'[data-testid="cell-0-operation"] > [data-testid="dust-view-button"]'
).
click
();
cy
.
get
(
'[data-testid="menu-item-dust-overview"] > span'
).
click
();
}
if
(
$body
.
find
(
'[data-testid="cell-0-operation"] > [data-testid="dust-edit-button"]'
).
length
)
{
cy
.
get
(
'[data-testid="cell-0-operation"] > [data-testid="dust-edit-button"]'
).
click
();
cy
.
get
(
'[data-testid="confirm-button"]'
).
click
();
}
});
/* ==== End Cypress Studio ==== */
});
})
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment