简体   繁体   中英

backstopjs missmatch errors issue

I am new to backstopjs, I was able to download it globally. My project directory structure looks like the following. I set up instance of backstopjs in my tests/backstopjs directory with backstop init :

测试/backstop.js中安装了backstop

The page I want to reference is index.html in my app directory:

索引文件位置

My scenarios in the backstop.js file are the following:

"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
    }
  ],

I am trying to taget the list-content class on my index.html page.

The error I am getting is:

report | *** Mismatch errors found ***
      COMMAND | Command `report` ended with an error after [0.089s]
      COMMAND | Command `test` ended with an error after [32.08s]

And the report page result:

backstopjs结果页

Is my url path completely wrong, or is it something else I have missed?

Sorry, my url path was wrong, I tried it out on a simpler project setup. But from the screen dumps above, can someone suggest the proper relative path for my url setting from my tests/backstopjs folder where the backstop.json exits to my app where the index.html file exists?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM