Exemple #1
0
    def test_get_driver(self):
        drivers = [
            'aalib', 'android', 'arm', 'cocoa', 'dga', 'directx', 'directfb',
            'dummy', 'emscripten', 'fbcon', 'ggi', 'haiku', 'khronos',
            'kmsdrm', 'nacl', 'offscreen', 'pandora', 'psp', 'qnx',
            'raspberry', 'svgalib', 'uikit', 'vgl', 'vivante', 'wayland',
            'windows', 'windib', 'winrt', 'x11'
        ]
        driver = display.get_driver()
        self.assertIn(driver, drivers)

        display.quit()
        with self.assertRaises(pygame.error):
            driver = display.get_driver()
Exemple #2
0
    def test_get_driver(self):
        drivers = [
            "aalib",
            "android",
            "arm",
            "cocoa",
            "dga",
            "directx",
            "directfb",
            "dummy",
            "emscripten",
            "fbcon",
            "ggi",
            "haiku",
            "khronos",
            "kmsdrm",
            "nacl",
            "offscreen",
            "pandora",
            "psp",
            "qnx",
            "raspberry",
            "svgalib",
            "uikit",
            "vgl",
            "vivante",
            "wayland",
            "windows",
            "windib",
            "winrt",
            "x11",
        ]
        driver = display.get_driver()
        self.assertIn(driver, drivers)

        display.quit()
        with self.assertRaises(pygame.error):
            driver = display.get_driver()