/* Any copyright is dedicated to the Public Domain.
  http://creativecommons.org/publicdomain/zero/1.0/ */
/* eslint-disable max-len */

"use strict";

/*
 * THIS FILE IS AUTOGENERATED. DO NOT MODIFY BY HAND. RUN TESTS IN FIXTURES/ TO UPDATE.
 */

const { NetworkEventMessage } =
  require("devtools/client/webconsole/new-console-output/types");

let stubPreparedMessages = new Map();
let stubPackets = new Map();
stubPreparedMessages.set("GET request", new NetworkEventMessage({
  "id": "1",
  "actor": "server1.conn0.child1/netEvent29",
  "level": "log",
  "isXHR": false,
  "request": {
    "url": "http://example.com/browser/devtools/client/webconsole/new-console-output/test/fixtures/stub-generators/inexistent.html",
    "method": "GET"
  },
  "response": {},
  "source": "network",
  "type": "log",
  "timeStamp": 1479159937660,
  "groupId": null
}));

stubPreparedMessages.set("XHR GET request", new NetworkEventMessage({
  "id": "1",
  "actor": "server1.conn1.child1/netEvent29",
  "level": "log",
  "isXHR": true,
  "request": {
    "url": "http://example.com/browser/devtools/client/webconsole/new-console-output/test/fixtures/stub-generators/inexistent.html",
    "method": "GET"
  },
  "response": {},
  "source": "network",
  "type": "log",
  "timeStamp": 1479159938522,
  "groupId": null
}));

stubPreparedMessages.set("XHR POST request", new NetworkEventMessage({
  "id": "1",
  "actor": "server1.conn2.child1/netEvent29",
  "level": "log",
  "isXHR": true,
  "request": {
    "url": "http://example.com/browser/devtools/client/webconsole/new-console-output/test/fixtures/stub-generators/inexistent.html",
    "method": "POST"
  },
  "response": {},
  "source": "network",
  "type": "log",
  "timeStamp": 1479159939328,
  "groupId": null
}));

stubPackets.set("GET request", {
  "from": "server1.conn0.child1/consoleActor2",
  "type": "networkEvent",
  "eventActor": {
    "actor": "server1.conn0.child1/netEvent29",
    "startedDateTime": "2016-10-15T23:12:04.196Z",
    "timeStamp": 1479159937660,
    "url": "http://example.com/browser/devtools/client/webconsole/new-console-output/test/fixtures/stub-generators/inexistent.html",
    "method": "GET",
    "isXHR": false,
    "cause": {
      "type": 3,
      "loadingDocumentUri": "http://example.com/browser/devtools/client/webconsole/new-console-output/test/fixtures/stub-generators/test-network-event.html",
      "stacktrace": [
        {
          "filename": "http://example.com/browser/devtools/client/webconsole/new-console-output/test/fixtures/stub-generators/test-tempfile.js",
          "lineNumber": 3,
          "columnNumber": 1,
          "functionName": "triggerPacket",
          "asyncCause": null
        },
        {
          "filename": "chrome://mochikit/content/tests/BrowserTestUtils/content-task.js line 52 > eval",
          "lineNumber": 4,
          "columnNumber": 7,
          "functionName": null,
          "asyncCause": null
        },
        {
          "filename": "chrome://mochikit/content/tests/BrowserTestUtils/content-task.js",
          "lineNumber": 53,
          "columnNumber": 20,
          "functionName": null,
          "asyncCause": null
        }
      ]
    },
    "private": false
  }
});

stubPackets.set("XHR GET request", {
  "from": "server1.conn1.child1/consoleActor2",
  "type": "networkEvent",
  "eventActor": {
    "actor": "server1.conn1.child1/netEvent29",
    "startedDateTime": "2016-10-15T23:12:05.690Z",
    "timeStamp": 1479159938522,
    "url": "http://example.com/browser/devtools/client/webconsole/new-console-output/test/fixtures/stub-generators/inexistent.html",
    "method": "GET",
    "isXHR": true,
    "cause": {
      "type": 11,
      "loadingDocumentUri": "http://example.com/browser/devtools/client/webconsole/new-console-output/test/fixtures/stub-generators/test-network-event.html",
      "stacktrace": [
        {
          "filename": "http://example.com/browser/devtools/client/webconsole/new-console-output/test/fixtures/stub-generators/test-tempfile.js",
          "lineNumber": 4,
          "columnNumber": 1,
          "functionName": "triggerPacket",
          "asyncCause": null
        },
        {
          "filename": "chrome://mochikit/content/tests/BrowserTestUtils/content-task.js line 52 > eval",
          "lineNumber": 4,
          "columnNumber": 7,
          "functionName": null,
          "asyncCause": null
        },
        {
          "filename": "chrome://mochikit/content/tests/BrowserTestUtils/content-task.js",
          "lineNumber": 53,
          "columnNumber": 20,
          "functionName": null,
          "asyncCause": null
        }
      ]
    },
    "private": false
  }
});

stubPackets.set("XHR POST request", {
  "from": "server1.conn2.child1/consoleActor2",
  "type": "networkEvent",
  "eventActor": {
    "actor": "server1.conn2.child1/netEvent29",
    "startedDateTime": "2016-10-15T23:12:07.158Z",
    "timeStamp": 1479159939328,
    "url": "http://example.com/browser/devtools/client/webconsole/new-console-output/test/fixtures/stub-generators/inexistent.html",
    "method": "POST",
    "isXHR": true,
    "cause": {
      "type": 11,
      "loadingDocumentUri": "http://example.com/browser/devtools/client/webconsole/new-console-output/test/fixtures/stub-generators/test-network-event.html",
      "stacktrace": [
        {
          "filename": "http://example.com/browser/devtools/client/webconsole/new-console-output/test/fixtures/stub-generators/test-tempfile.js",
          "lineNumber": 4,
          "columnNumber": 1,
          "functionName": "triggerPacket",
          "asyncCause": null
        },
        {
          "filename": "chrome://mochikit/content/tests/BrowserTestUtils/content-task.js line 52 > eval",
          "lineNumber": 4,
          "columnNumber": 7,
          "functionName": null,
          "asyncCause": null
        },
        {
          "filename": "chrome://mochikit/content/tests/BrowserTestUtils/content-task.js",
          "lineNumber": 53,
          "columnNumber": 20,
          "functionName": null,
          "asyncCause": null
        }
      ]
    },
    "private": false
  }
});

module.exports = {
  stubPreparedMessages,
  stubPackets,
};
