modified bidding slightly and added some tests