"use strict";

var _parser = _interopRequireDefault(require("../parsers/parser"));

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread(); }

function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance"); }

function _iterableToArray(iter) { if (Symbol.iterator in Object(iter) || Object.prototype.toString.call(iter) === "[object Arguments]") return Array.from(iter); }

function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = new Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } }

var examples = [" 0", "0 ", "[\n0\n]", "// This is a comment\n    42", "42\n    // This is a comment\n    ", "\n    filter\n    // foo bar / asd\n    $ => \"Hello\"\n    ", "\n    filter\n    // foo bar / asd\n    $ =>\n    // foo bar / asd\n    \"Hello\"\n    ", "\n    filter // sadsadasd\n    // foo bar / asd\n    $ // sasadasdasd\n    // asdasd \n    => // asdsada sdsad\n    // foo bar / asd\n    \"Hello\"\n    ", "\n    3 // foo\n    + 4\n    ", "\n    3 + //foo\n    //goo \n    4 // foo\n    ", "\n    3 +\n    //goo \n    4\n    *\n    \"hello\" // 324234\n    - // asdsad\n    4\n    ", "\n    // foo\n    join //ffoo\n    // foo\n    \"Hello\" // foo\n    //foo\n    ", "\n    // foo\n    -\n    // foo\n    4\n    ", "\n    [4, 3] //foo\n    // foo\n    [3, 2] // 3423\n    .foo // foo\n    // #\n    ", "\n    [\n    // foo\n    5\n    , // foo\n    43 //foo\n    ,\n    \"Hello\" // foo\n    , // foo\n    34234 , //\n    \"Hello\" //\n    ] //\n    ", "\n    // foo\n    ($foo + $bar // foo\n     where //foo\n       $foo = 3 //foo\n    )\n    where\n      $bar // foo\n        = // foo\n         4\n    "];
var extendedExamples = examples.concat(_toConsumableArray(examples.map(function (example) {
  return example.replace('//', '#');
})));
describe('whitespace tests', function () {
  extendedExamples.forEach(function (example) {
    it("parses '".concat(example.slice(0, 25), "'"), function () {
      (0, _parser.default)(example);
    });
  });
});