Don't do this. Write a wrapper around Casper's `cobj.getFormValues()` method.