define(function(require) {
  "use strict";

  var Backbone = require("backbone");
  var Router = require("router");

  // Test that the Router exists.
  describe("Router", function() {
    it("should exist", function() {
      expect(Router).to.exist;
      expect(new Router()).to.be.an.instanceof(Backbone.Router);
    });

    it("should run index method when history is started", function() {
      Backbone.history.start();
    });
  });
});

define(function(require) {
  "use strict";

  var Backbone = require("backbone");
  var Router = require("router");

  // Test that the Router exists.
  describe("Router", function() {

    beforeEach(function() {
      this.mainEl = document.createElement('main');
      document.body.appendChild(this.mainEl);
    });

    afterEach(function() {
      document.body.removeChild(this.mainEl);
    });

    it("should exist", function() {
      expect(Router).to.exist;
      expect(new Router()).to.be.an.instanceof(Backbone.Router);
    });

    it("should run index method when history is started", function() {
      Backbone.history.start();
    });
  });
});

Fix application Router unit tests
Fix application Router unit tests

The application Router expects the document body to contain a `<main>`
element. Without it, all instances create a Layout without an element,
resulting in an error when LayoutManager attempts to render.

Ensure that the necessary element is present in the document before each
Router unit test.
