Add unit test for bgprocess smooth recovery