add generating in background
remove spawnling from controller tests
add some privilege testing