title: Routing in Marionette using a Marionette Object — Can't make it work
body: <p>I am trying Marionette for the first time and am very much confused about its routing.</p>
  
  <p>Here's what I have so far: a Backbone model, a Backbone collection, a Marionette Layout view, a Marionette Collection View, a couple of Marionette Item views. The views are hooked together in a Marionette object like so:</p>
  
  <pre><code>var Orchestrator = Marionette.Object.extend({
    initialize: function(layout) {
      this.layout = layout;
      // adding a collection view
      // showing the collection view in the layout view
  
      // all is honky-dory
    },
  
    // And here is a test function I want to call when I go to localhost:8080/#test:
  
    test: function() {
      console.log('HELLOOO!!!');
    }
  
  });
  </code></pre>
  
  <p>And here comes the confusion. I am trying to set up the router:</p>
  
  <pre><code>var Router = Marionette.AppRouter.extend({
    initialize: function(controller) {
      // the 'controller' is an instance of my Orchestrator object defined above
      this.controller = controller;
      console.log(this.controller.test); // the method shows up correctly
      this.appRoutes = {
        'test': 'test'
      };
    }
  });
  </code></pre>
  
  <p>Then I initialize the Router: <code>var router = new Router(orchestrator);</code> and start the Marionette app.</p>
  
  <p>The <code>console.log</code> statement in the router shows that 1) it is being initialized, 2) the 'controller' is the correct Marionette object, and 3) the 'controller' has the method <code>test</code> on it.</p>
  
  <p>However, when I navigate to <code>localhost:8080/#test</code> (my app is served at <code>localhost:8080</code>), I do not see any evidence that the <code>test</code> method of the <code>Orchestrator</code> object has been called — my 'HELLO' message does not appear in the console. There are no errors in the console either.</p>
  
  <p>Could you please suggest what the matter might be and how to fix this? I've been searching through docs, but have not found any answers so far. </p>