我是backstopjs的新手,我可以在全球下载它。我的项目目录结构如下所示。我用backstop init在我的test/ backstopjs目录中设置了backstopjs的实例:

我要引用的页面是我的应用程序目录中的index.html:

我在backstop.js文件中的场景如下:
"scenarios": [
{
"label": "My index test",
"url": "~/app/index.html",
"referenceUrl": "",
"readyEvent": "",
"readySelector": "",
"delay": 0,
"hideSelectors": [],
"removeSelectors": [],
"hoverSelector": "",
"clickSelector": "",
"postInteractionWait": "",
"selectors": [
".list-content"
],
"selectorExpansion": true,
"misMatchThreshold" : 0.1,
"requireSameDimensions": true
}
],我正在尝试标记我的index.html页面上的list-content类。
我得到的错误是:
report | *** Mismatch errors found ***
COMMAND | Command `report` ended with an error after [0.089s]
COMMAND | Command `test` ended with an error after [32.08s]和报表页面结果:

是我的url路径完全错了,还是我漏掉了其他东西?
发布于 2018-01-05 02:57:54
对不起,我的url路径是错误的,我在一个更简单的项目设置上尝试了一下。但从上面的屏幕转储来看,有人能为我的index.html文件所在的应用程序的backstop.json /backstopjs文件夹中的url设置建议正确的相对路径吗?
https://stackoverflow.com/questions/48086702
复制相似问题