def setUpState(self, state):
        # Initial state is 'stopped'.
        if state == 'stopped':
            return

        # Starting the service with no delegate results in state 'idle'.
        self.monitor.startService()
        if state == 'idle':
            return

        # Setting up a delegate causes transition to state 'connecting'.
        if not self.monitor.delegate:
            self.monitor.delegate = self.onEntry
            self.monitor.connect()
        self.clock.advance(0)
        if state == 'connecting':
            return

        # If we want to reach aborting, force a reconnect while connecting.
        if state == 'aborting':
            self.monitor.connect(forceReconnect=True)
            return

        # Connecting the API causes a transition to state 'connected'
        self.api.connected()
        if state == 'connected':
            return

        # Forcing a reconnect while connected drops the connection
        self.monitor.connect(forceReconnect=True)
        if state == 'disconnecting':
            return

        # Actually lose the connection
        self.api.protocol.connectionLost(failure.Failure(ResponseDone()))
        if state == 'disconnected':
            return

        # When disconnected, the next state is usually 'waiting'
        if state == 'waiting':
            return
If the C{stripFlags} option is passed to C{runSequentially} then the
dataset/ETHPy150Open dustin/twitty-twister/twittytwister/test/test_twitter.py/TwitterMonitorTest.setUpState--crossover with--dataset/ETHPy150Open kuri65536/python-for-android/python-modules/twisted/twisted/trial/test/test_util.py/TestRunSequentially.test_stripFlags