Debugging and testing questions #2636
CyanideForBreakfast
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi, I'd like to ask an automated testing approach while developing something from the library to make the app robust.
How to test if the TUI application is running and rendering as desired? How to ensure the planes have the exact colors, with the correct text written on them and looks precisely as was designed? I wanted to see if we can make automated tests for these questions.
My approach was that if there was a way to "capture" the terminal view at any point and then we can compare it to an already saved "image" or "capture" and check if it looks exactly like that. How does one go about doing that for Notcurses? If there is any other terminal util that can do that for us, please do tell! I found there was an option
renderfp
option innotcurses_options
but don't know if that would've worked.Or is that even the right way or practice to test TUI application? A brief look over the
/tests
directory tells me that we test for edges cases here mostly. Are there tests that we implemented in Notcurses that use the methodology I mentioned earler?Noob here in TUI apps, so feel free to educate me.
Beta Was this translation helpful? Give feedback.
All reactions