def test_runInOrder(self):
        """
        L{Runner.run} calls the expected methods in order.
        """
        runner = DummyRunner(reactor=MemoryReactor())
        runner.run()

        self.assertEqual(
            runner.calledMethods,
            [
                "killIfRequested",
                "startLogging",
                "startReactor",
                "reactorExited",
            ]
        )

        L{Runner.run} calls the expected methods in order.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/application/runner/test/test_runner.py