add test for persistence of scope