Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

marcus (4582)

marcus
  marcus@thiesen.org
http://perl.thiesen.org/

My Modules:
Curses::UI
CPANPLUS::Shell::Curses
GraphViz::ISA::Multi
MPlayer.pm (unreleased)

Occupation:
Computer geek who studies computer science to become a Master of his Science, playing with Parrot, Perl and all the rest just for fun - did I mention geek?

Journal of marcus (4582)

Tuesday September 30, 2003
12:42 PM

Testing Curses::UI and version numbers

[ #14978 ]
I'm currently in a very constructive email chat with a (I guess) indish guy who keep constantly asking me how to do things in Curses::UI that are not even implemented. That's good, because he requested some rather usefull features like adding single items to a Listbox widget. Never thought of that and actually never did that.

When thinking about Curses::UI and hacking it I always want to keep backwards compatibility, that's because I'm lazy and don't want to change my own programs that use Curses::UI. This can't be bad for other people.

The problem is, as I took over Curses::UI there weren't really much tests. In fact, all tests in Curses::UI just test weather the modules compile, not their actual function.

But how to test something that is rather a visual thing than something you can catch in the source. I mean, usually you test a module by knowing what a method should return and then using Test::Simple or Test::Moore. I guess about 75% of all subs in Curses::UI don't return anything. They just do something on the screen. And they don't know weather their call just worked or didn't. That's rather strange.

It's actually not an excuse for not testing the 25% subs that return something. I'm going to do that before I release Curses::UI 0.80. The other problem that all the Test::* modules usually do output something, which can be hard if the screen is locked by Curses calls. This is a thing I've to figure out before I write the tests. The POD isn't tested either and this is something I consider as really bad. So besides all the other stuff I do I have to fix the and write tests for Curses::UI

Another thing I just wonder about is versioning of modules. I got Curses::UI when it was version 0.70 or something and kept increasing the version number in steps of 0.01 for quite a while now. I think it's psychological more usefull to releas a verion 1.0 someday to tell people that I believe it is ready, stable and useable. Maybe I should create something like a releas plan. It should be easy to release a 1.0 version till christmas. I will release the next version, that has mostly bugfixes and the new tests I'm going to write till end of this month as a 0.8 version. After waiting for some fixes I'll go up to version 0.9 and if I find now showstoppers I'll release it as 1.0. Sounds far more easy than it will be. Only in writing all those test I will intoduce new bugs, find some, fix some bugs and write some new features, so I shouldn't be that optimistic.

We'll see