add test for flash persistence