Tidy Gatekeeper & gateway
Write tests for gateway