ENH: add unit test for previous state grid search
ENH: add unit test for previous state grid search