frougon / pythondialog

Python wrapper for the Unix "dialog" utility
GNU Lesser General Public License v2.1
25 stars 8 forks source link

best practice for unittesting? #2

Closed Sispheor closed 7 years ago

Sispheor commented 7 years ago

Hi, thanks for your lib.

I don't find any doc about testing. Is that possible? If yes, what is the best practice? Thank you !

Here is the class I would like to test for giving you an idea if it can help.

frougon commented 7 years ago

Hi Nicolas,

I'm not sure it's very helpful, but I'd try with libs that allow faking keystrokes. I have good experience with python-evdev for faking mouse clicks, and apparently it can work with keyboards too. You may have to adjust the permissions of /dev/uinput, though...

Regards

Sispheor commented 7 years ago

Ok. I'll give a try. Thanks.