added repro for a unit test that failed and additional logic to prevent failure in the future