[TIP] testing html forms

alex argriffi at ncsu.edu
Fri Aug 29 07:12:36 PDT 2008


I want to start testing my python code.  I have a bunch of function 
pairs such that one of the functions returns the html code for a form 
(including default field values) and the other function takes a 
field_storage object as input and returns an html response.  For my 
first test, I want a python function that can convert the html form 
output from the first function to a field_storage object that holds the 
default field values.  Does something like that exist?  I imagine that a 
cleaner solution would be to build the field_storage object as the first 
function writes the html, but that would require a bunch of rewriting.  

More information about the testing-in-python mailing list