added test for stock formula