modified constructor to include vcr flag to enable vcr mode
added vcr recording for unittesting purposes