Fleshing out regression tests
Move test script to perl for mac/win/linux compatiblity. Improve regression testing