 if typeof process isnt 'undefined' and process.execPath and process.execPath.match /node|iojs/
   chai = require 'chai' unless chai
-  graph = require '../src/lib/Graph.coffee'
-  journal = require '../src/lib/Journal.coffee'
+  noflo = require '../src/lib/NoFlo.coffee'
 else
-  graph = require 'noflo/src/lib/Graph.js'
-  journal = require 'noflo/src/lib/Journal.js'
+  noflo = require 'noflo'
 
 describe 'Journal', ->
   describe 'connected to initialized graph', ->
-    g = new graph.Graph
-    g.addNode 'Foo', 'Bar'
-    g.addNode 'Baz', 'Foo'
-    g.addEdge 'Foo', 'out', 'Baz', 'in'
-    j = new journal.Journal(g)
+    g = new noflo.graph.Graph
+    g.addNode 'Foo', 'Bar'
+    g.addNode 'Baz', 'Foo'
+    g.addEdge 'Foo', 'out', 'Baz', 'in'
+    j = new noflo.journal.Journal(g)
     it 'should have just the initial transaction', ->
       chai.expect(j.store.lastRevision).to.equal 0
 
   describe 'following basic graph changes', ->
-    g = new graph.Graph
-    j = new journal.Journal(g)
+    g = new noflo.graph.Graph
+    j = new noflo.journal.Journal(g)
     it 'should create one transaction per change', ->
       g.addNode 'Foo', 'Bar'
       g.addNode 'Baz', 'Foo'

      chai.expect(g.toJSON()).to.deep.equal graphBeforeError

  describe 'undo/redo of metadata changes', ->
    g = new graph.Graph
    j = new journal.Journal(g)
    g.addNode 'Foo', 'Bar'
    g.addNode 'Baz', 'Foo'
    g.addEdge 'Foo', 'out', 'Baz', 'in'

      chai.expect(g.nodes.length).to.equal 1

  describe 'linear undo/redo', ->
    g = new noflo.graph.Graph
    j = new noflo.journal.Journal(g)
    g.addNode 'Foo', 'Bar'
    g.addNode 'Baz', 'Foo'
    g.addEdge 'Foo', 'out', 'Baz', 'in'
