def setUp(self):
        # Mock Registry
        Registry.getConfig = MagicMock(return_value=None)

        # Load configuration defaults
        config = Config()
        config.defaults()

        self.server = NetServer(config)
        self.webserver = WebServer(self.server)
        self.restapi = self.webserver.restapi
    def setUp(self):
        # Mock Registry
        Registry.getConfig = MagicMock(return_value=None)

        # Initialise Database object to create relationships
        db = Database()
        db.register()

        # Load configuration defaults
        config = Config()
        config.defaults()

        self.server = NetServer(config)
        self.webserver = WebServer(self.server)
        self.restapi = self.webserver.restapi