function countNodes() {
        let graph = heimdallGraph.loadFromNode(heimdall.root);
        let count = 0;

        // eslint-disable-next-line no-unused-vars
        for (let n of graph.dfsIterator()) {
          ++count;
        }

        return count;
      }
    beforeEach(function() {
      instrumentation = new Instrumentation({ ui: new MockUI() });

      let heimdall = new Heimdall();
      let root;
      let a1 = heimdall.start({ name: 'a1', broccoliNode: true, broccoliCachedNode: false });
      root = heimdall.current;
      let b1 = heimdall.start({ name: 'b1' });
      let c1 = heimdall.start({ name: 'c1', broccoliNode: true, broccoliCachedNode: true });
      c1.stop();
      let c2 = heimdall.start({ name: 'c2', broccoliNode: true, broccoliCachedNode: false });
      c2.stop();
      b1.stop();
      a1.stop();

      instrTree = heimdallGraph.loadFromNode(root);
      process.env.EMBER_CLI_INSTRUMENTATION = '1';
    });
 _instrumentationTreeFor(name) {
   return heimdallGraph.loadFromNode(this.instrumentations[name].node);
 }
Example #4
0
Instrumentation.prototype._instrumentationTreeFor = function(name) {
  return heimdallGraph.loadFromNode(this.instrumentations[name].node);
};