Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -166,9 +166,21 @@ protected Promise<IdeSession> connect(TableSourceBuilder tables) {
}

private Promise<IdeSession> runAllScriptsInOrder(IdeSession session, List<String> code) {
String block = String.join("\n", code);
delayTestFinish(4000);
return session.runCode(block).then(ignore -> Promise.resolve(session));
Promise<IdeSession> result = Promise.resolve(session);
for (int i = 0; i < code.size(); i++) {
final int index = i;
result = result.then(ignore -> {
delayTestFinish(4000 + index);

return session.runCode(code.get(index));
}).then(r -> {
if (r.getError() != null) {
return Promise.reject(r.getError());
}
return Promise.resolve(session);
});
}
return result;
}

public IThenable.ThenOnFulfilledCallbackFn<IdeSession, JsTable> table(String tableName) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ public class ChartDataTestGwt extends AbstractAsyncGwtTestCase {
"my_col_defs = {\"ID\": dht.int32, \"Value\": dht.string, \"Deleted\": dht.bool_}",
"ug = jpy.get_type('io.deephaven.engine.updategraph.impl.EventDrivenUpdateGraph').newBuilder('test').existingOrBuild()",
"exec_ctx = ExecutionContext(get_exec_ctx().j_object.withUpdateGraph(ug))",
"with exec_ctx:",
" input = input_table(col_defs=my_col_defs, key_cols=\"ID\")",
" result = input.without_attributes('InputTable').where(\"!Deleted\").sort(\"ID\")");
"with exec_ctx:\n" +
" input = input_table(col_defs=my_col_defs, key_cols=\"ID\")\n" +
" result = input.without_attributes('InputTable').where(\"!Deleted\").sort(\"ID\")");

@Override
public String getModuleName() {
Expand Down