mocks.js
function(select, success, err) {
			try {
				var chars = new antlr4.InputStream(select);
				var lexer = new SelectLexer(chars);
				var tokens  = new antlr4.CommonTokenStream(lexer);
				var parser = new SelectParser(tokens);
				parser.buildParseTrees = true;
				var tree = parser.select();
				console.log(tree.toStringTree());
				var listener = new QueryBuilderListener(sforce.db);
				antlr4.tree.ParseTreeWalker.DEFAULT.walk(listener, tree);
				var result = listener.query.getResult();
				if(success) 
					success(result);
				return result;
			} catch(e) {
				if(err) 
					err(e);
				return e;
			}
		}
function(select, success, err) {
			try {
				var chars = new antlr4.InputStream(select);
				var lexer = new SelectLexer(chars);
				var tokens  = new antlr4.CommonTokenStream(lexer);
				var parser = new SelectParser(tokens);
				parser.buildParseTrees = true;
				var tree = parser.select();
				console.log(tree.toStringTree());
				var listener = new QueryBuilderListener(sforce.db);
				antlr4.tree.ParseTreeWalker.DEFAULT.walk(listener, tree);
				var result = listener.query.getResult();
				if(success) 
					success(result);
				return result;
			} catch(e) {
				if(err) 
					err(e);
				return e;
			}
		}
Run a select query on the database and call success(...) or err(...) on success/failure