added permission test aswell