Permalink
Browse files

test changes

  • Loading branch information...
1 parent fd75419 commit 1443ab68746394fb5d72e034d65813fe937d86b5 @AlgoTrader committed Jan 9, 2013
Showing with 6 additions and 2 deletions.
  1. +6 −2 test/list_market_book.js
@@ -14,13 +14,14 @@ function listMarketCatalogue(data, cb) {
if(!cb)
cb = data;
- var filter = { eventTypeIds: [1], marketTypeCodes:['MATCH_ODDS']};
+ var filter = { eventTypeIds: [2], marketTypeCodes:['MATCH_ODDS']};
var what = ['EVENT', 'RUNNER_DESCRIPTION'];
session.listMarketCatalogue({filter:filter, marketProjection:what, maxResults:60}, function(err,res) {
console.log("listMarketCatalogue err=%s duration=%s", err, res.duration()/1000);
console.log("Request:%s\n", JSON.stringify(res.request, null, 2))
console.log("Response:%s\n", JSON.stringify(res.response, null, 2));
data.selectedMarket = res.response.result[0];
+ data.selectedMarket2 = res.response.result[1];
cb(err,data);
});
}
@@ -31,7 +32,10 @@ function listMarketBook(data, cb) {
//var price = ['EX_ALL_OFFERS'];
var price = ['EX_ALL_OFFERS', 'EX_TRADED'];
- session.listMarketBook({marketIds:[data.selectedMarket.marketId], priceProjection:price}, function(err,res) {
+ var order = 'ALL';
+ var match = 'NO_ROLLUP';
+ //session.listMarketBook({marketIds:[data.selectedMarket.marketId,data.selectedMarket2.marketId], priceProjection:price, orderProjection:order, matchProjection:match}, function(err,res) {
+ session.listMarketBook({marketIds:[data.selectedMarket.marketId,data.selectedMarket2.marketId], matchProjection:match}, function(err,res) {
console.log("listMarketBook err=%s duration=%s", err, res.duration()/1000);
console.log("Request:%s\n", JSON.stringify(res.request, null, 2))
console.log("Response:%s\n", JSON.stringify(res.response, null, 2));

0 comments on commit 1443ab6

Please sign in to comment.