   , (error) ->
     callback error, graph
 
-exports.buildGraph = buildGraph
+### Exports ###
+
+module.exports = {Graph, GraphHandler, buildGraph}

    node.addEdge @nodeFor dependency

  dependenciesFor: (item) ->
    ### return an array with all depdenencies for *item* ###
    node = @nodeFor item
    resolved = @resolveNode node
    resolved.splice resolved.indexOf(node), 1
    return resolved.map (node) -> node.item

  ### private ###


  proxy = GraphHandler.proxy contents, (dep) ->
    graph.addDependency current, dep

  locals.contents = proxy # TODO: don't modify locals

  async.eachSeries items, (item, callback) ->
    current = item
