def _securedFunction(self, startUID, startGID, wantUID, wantGID):
        """
        Check if wanted UID/GID matched start or saved ones.
        """
        self.assertTrue(wantUID == startUID or
                        wantUID == self.mockos.seteuidCalls[-1])
        self.assertTrue(wantGID == startGID or
                        wantGID == self.mockos.setegidCalls[-1])

        Check if wanted UID/GID matched start or saved ones.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/python/test/test_util.py