Exemple #1
0
    def test_writer(self):
        """Tests the writer"""

        import sys
        sys.argv = ['']

        self.assertRaises(SystemExit, mute_stderr(daemon.main))
        self.assertRaises(SystemExit, mute_stderr(daemon.main), [])
        self.assertIsNone(daemon.main(['stop']))
Exemple #2
0
    def test_writer(self):
        """Tests the writer"""

        import sys
        sys.argv = ['']

        self.assertRaises(
            SystemExit,
            mute_stderr(daemon.main)
        )
        self.assertRaises(
            SystemExit,
            mute_stderr(daemon.main),
            []
        )
        self.assertIsNone(daemon.main(['stop']))
Exemple #3
0
    def test_main(self):
        """Tests the main function"""

        self.assertIsNone(daemon.main(['status']))
        self.assertIsNone(daemon.main(['stop']))
Exemple #4
0
    def test_main(self):
        """Tests the main function"""

        self.assertIsNone(daemon.main(['status']))
        self.assertIsNone(daemon.main(['stop']))