1
0
Fork 0

Merge branch 'devel' of github.com:triAGENS/ArangoDB into devel

This commit is contained in:
Thomas Schmidts 2014-07-11 09:29:46 +02:00
commit 256c7d51de
2 changed files with 13 additions and 4 deletions

View File

@ -20,6 +20,9 @@
isTestSetup : function () {
return undefined;
},
cleanUp : function () {
return undefined;
},
destroy : function () {
return undefined;
}
@ -158,10 +161,12 @@
});
spyOn(window.App, "navigate");
spyOn(window.App.clusterPlan, "isTestSetup").andReturn(false);
spyOn(window.App.clusterPlan, "cleanUp");
spyOn(jquerydummy, "modal");
view.submitEditPlan();
expect(jquerydummy.modal).toHaveBeenCalledWith("hide");
expect(window.App.clusterPlan.cleanUp).toHaveBeenCalled();
expect(window.App.navigate).toHaveBeenCalledWith("planAsymmetrical", {trigger : true});
});
@ -178,9 +183,11 @@
});
spyOn(window.App, "navigate");
spyOn(window.App.clusterPlan, "isTestSetup").andReturn(true);
spyOn(window.App.clusterPlan, "cleanUp");
spyOn(jquerydummy, "modal");
view.submitEditPlan();
expect(window.App.clusterPlan.cleanUp).toHaveBeenCalled();
expect(jquerydummy.modal).toHaveBeenCalledWith("hide");
expect(window.App.navigate).toHaveBeenCalledWith("planTest", {trigger : true});
@ -198,13 +205,16 @@
return jquerydummy;
}
});
spyOn(window, "ClusterPlan").andReturn(window.App.clusterPlan);
spyOn(window.App, "navigate");
spyOn(window.App, "planScenario");
spyOn(window.App.clusterPlan, "cleanUp");
spyOn(window.App.clusterPlan, "destroy");
spyOn(jquerydummy, "modal");
view.submitDeletePlan();
expect(jquerydummy.modal).toHaveBeenCalledWith("hide");
expect(window.App.clusterPlan.cleanUp).toHaveBeenCalled();
expect(window.App.planScenario).toHaveBeenCalled();
});

View File

@ -5855,7 +5855,6 @@ function GENERAL_GRAPH_NEIGHBORS (graphName,
options.startVertexCollectionRestriction = options.vertexCollectionRestriction;
}
}
var neighbors = [],
params = TRAVERSAL_PARAMS(),
factory = TRAVERSAL.generalGraphDatasourceFactory(graphName);
@ -5865,11 +5864,11 @@ function GENERAL_GRAPH_NEIGHBORS (graphName,
params.paths = true;
options.edgeExamples = options.edgeExamples || {};
params.visitor = TRAVERSAL_NEIGHBOR_VISITOR;
var graph = RESOLVE_GRAPH_TO_DOCUMENTS(graphName, options);
params.followEdges = MERGE_EXAMPLES_WITH_EDGES(options.edgeExamples, graph.edges);
if (params.followEdges.length === 0) {
return [];
}
graph.fromVertices.forEach(function (v) {
var e = TRAVERSAL_FUNC("GRAPH_NEIGHBORS",
factory,