【发布时间】:2018-04-04 21:42:49
【问题描述】:
我正在使用奏鸣曲管理包来管理我们的课程,并且我正在使用 behat 创建测试以确保一切正常。
但问题是,当我尝试使用 behat 添加新元素时,出现此错误:
When I visit the advertisement admin page
And I follow "Add new"
And I fill in "Url" with "http://www.example.com"
And I fill in "Video Source" with "http://www.youtube.com"
And I fill in "Text" with "Test new"
And I press "Create and return to list"
The selected node does not have a form ancestor.
问题是因为这个按钮不在表单中,但这是由奏鸣曲管理员管理的。
那么有什么方法可以点击这个按钮而不出现这个错误?
【问题讨论】:
-
如果可能,请添加您遇到的错误的堆栈跟踪和按钮的 html sn-p。