Fixes in tests, more helpers in statefspp