added Sandbox.use unit test and fixed an issue with the dependency injection