mirror of
https://github.com/jtgans/g13gui.git
synced 2025-07-08 00:47:25 -04:00
The whole project at this point is entirely python, with no g13d present anywhere, so let's clean up the tree somewhat and make it flatter.
29 lines
661 B
Python
29 lines
661 B
Python
import unittest
|
|
import time
|
|
|
|
from g13gui.bitwidgets.display import Display
|
|
from g13gui.bitwidgets.x11displaydevice import X11DisplayDevice
|
|
|
|
|
|
class DisplayTests(unittest.TestCase):
|
|
def setUp(self):
|
|
self.dd = X11DisplayDevice(self.__class__.__name__)
|
|
self.dd.start()
|
|
time.sleep(0.25)
|
|
self.d = Display(self.dd)
|
|
|
|
def tearDown(self):
|
|
time.sleep(1)
|
|
self.dd.shutdown()
|
|
self.dd.join()
|
|
|
|
def testUpdate(self):
|
|
ctx = self.d.getContext()
|
|
ctx.line((0, 0)+(160, 48), fill=1)
|
|
ctx.line((160, 0)+(0, 48), fill=1)
|
|
self.d.commit()
|
|
|
|
|
|
if __name__ == '__main__':
|
|
unittest.main()
|