Added a test and tightened up test conditions
Made tests more stringent
Add some nice formatting