Skip to content

Convert TestEmptyInput.tcl to python

This is a conversion of TestEmptyInput from TCL to Python.

There are some differences from the TCL version:

  • There is a command line interface allowing you to:
    • Select verbose or quiet mode (default).
    • Select an individual or a list of classes for testing. The default is to get all the VTK classes and test them.
    • Error handling is better in Python so it is possible to produce a good summary:
Update() worked:  841
Update() failed:  1074
Included in Update() failed are the following: 
	Abstract classes:  275
	Non-existent classes:  0
	No concrete implementation:  1
	No observer could be added:  1
	No Update():  14
	No SetInput(): 831
	No Shutdown():  5
Summary:
Not Tested:  10
Total number of classes tested:  1915
Total number of classes:  1925
Finished.
  • The original TCL classExceptions variable has been partitioned into classLinuxExceptions and classWindowsExceptions. In addition, classes have been removed from these that were tested and found to be OK.

Known issues:

  • There seem to be memory issues relating to Windows/VTK/Python in a similar manner to the TCL original. I have no idea how to track these down. Look at the comments in Main() for one approach I tried.

Merge request reports