{
  "tasks": [
    {
      "id": "login-ok",
      "name": "Sign in with the demo account reaches the account page",
      "startUrl": "https://replaycheck-near.mmix.biz/shop/login",
      "steps": [
        { "action": "fill", "target": "#email", "text": "demo@northwind.test" },
        { "action": "fill", "target": "#password", "text": "replay-me" },
        { "action": "click", "target": "button[type=submit]" },
        { "action": "wait", "target": "#flash.success" }
      ],
      "expect": [
        { "urlContains": "/shop/account" },
        { "textContains": "Recent orders" }
      ]
    },
    {
      "id": "login-regression",
      "name": "A wrong password is rejected with a clear message",
      "startUrl": "https://replaycheck-near.mmix.biz/shop/login",
      "steps": [
        { "action": "fill", "target": "#email", "text": "demo@northwind.test" },
        { "action": "fill", "target": "#password", "text": "wrong-password" },
        { "action": "click", "target": "button[type=submit]" },
        { "action": "wait", "target": "#flash.error" }
      ],
      "expect": [
        { "judge": "The page tells the user their password is invalid and does not show the account page." }
      ]
    }
  ]
}
