Failed Conditions
Pull Request — master (#1135)
by Lasse
01:54
created

coalib.tests.output.printers.LocalTestBear   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 4
Duplicated Lines 0 %
Metric Value
dl 0
loc 4
rs 10
wmc 1
1
import subprocess
2
import sys
3
4
sys.path.insert(0, ".")
5
from coalib.output.printers.EspeakPrinter import EspeakPrinter
6
import unittest
7
8
9
class EspeakPrinterTest(unittest.TestCase):
10
    def test_voice_printer(self):
11
        self.uut = EspeakPrinter()
12
        self.uut.print("The", "espeak", "printer", "works!")
13
        self.uut.close()
14
15
16
def skip_test():
17
    try:
18
        subprocess.Popen(['espeak'])
19
        return False
20
    except OSError:
21
        return "eSpeak is not installed."
22
23
24
if __name__ == '__main__':
25
    unittest.main(verbosity=2)
26