Besides Graphical User Interface, our product also has the command line interface, which provides complete product's functionality. The commands are normally used in scripts to speed up commonly performed tasks.
We in the QA used to write perl scripts, which tested some combinations and some options of availbale CLI commands, but not all of them.
What kind of tools are you using for testing command line interface?
We have tested some CAD applications which had command line interface. The tool that worked great for us was SilkTest. If you are thinking along the same lines and/ or have a copy of SilkTest check out the TypeKeys () method which is the best way to get around the CLI.
I'd have to disagree with people who claim Silk or Mercury. They simply can not handle text in an interactive manner. Sure, you can type things, but it has hard time (if it can do it at all) to grab the text. All GUI based automation tool can not handle DOS graphics.
What I'd suggest is to take insulin's and Reace's adivce and glue them together. Based on my research, various groups recommend using execpt directly. What I'd suggest is to download CYGWIN, as insulin suggests, and make sure you install the expect module. You can write expect modules from there. Though the author of expect pushes his book, it's not worth it. There are several examples (I believe if you download the source on cygwin), that you can use to see how the entire thing behaves.
Other options is to use Microsoft's Windows Scripting. For purpose of doing simple stuff, it'll do the job. Only reason why I'd use silk or other tools is if your team is heavily invested in the test management piece and you want to integrate into the reporting. Otherwise, you are spending more time and money (licensing ain't cheap) on something that can be done better with a GNU software.