我正在尝试使用赛普拉斯从“反应可排序树”库中拖放元素 https://github.com/frontend-collective/react-sortable-tree#troubleshooting
但是,执行此操作的通常方法无效。我尝试过的事情:
cy.get(subject).trigger("mousedown", { which: 1, force: true })
.trigger("mousemove", { pageX: xPos, pageY: yPos, force: true })
.trigger("mouseup", { force: true })
OR
cy.get(subject).trigger("mousedown", { button: 0, force: true })
cy.get(target).trigger("mousemove")
.trigger("mouseup")
有人使用赛普拉斯在可排序的树上成功测试了拖放吗?
答案 0 :(得分:0)
cy.get(subject).trigger("dragstart")
cy.get(target).trigger("drop")
.trigger("dragend")
以上对我有用