added tests to market_spec.rb