Rajesh - 2004-05-14

I am trying to write a test case, which should test for maxlength (240 chars) of a text box. My test goes as below:

clickLinkWithText("Create");
setWorkingForm("form1");
setFormElement("txtDesc","aaaaaaaabbbbbbcccccddddddeeeeeffffffffggggggghhhhhhhhiiiiiiiijjjjjjjjjjjjjjjjjjjjjjjjkkkkkkkkkkkkkkkkkkkkklllllllllllllllllllllllllllllmmmmmmmmmmmmmmmmmmmmnnnnnnnnnnnnnnnnnnnooooooooooooooooppppppppppppppppppppqqqqqqqqqqqqrrrrrrrrrrrrrrssssssssssssssst");
assertTrue(!(getDialog().getFormParameterValue("Menu Alias").length() > 240));

Even though I try to insert more than 240 characters, its accepting it!, but when I try the same thing through browser, it cuts off other characters after 240...

How can I test for the same.

Thanx.
Raj