I think you need to use a string when setting a text field. Either use to_s to convert the value from fixnum to string when setting the field or use a quoted value in the yml file.
--- On Tue, 12/16/08, winstan <lucasdavidwinstan...@gmail.com> wrote: > From: winstan <lucasdavidwinstan...@gmail.com> > Subject: [wtr-general] undefined method `length' for 4324536:Fixnum > To: "Watir General" <watir-general@googlegroups.com> > Date: Tuesday, December 16, 2008, 3:28 PM > Hi all, > > In recent days i have made changes to the way i am > storing/using test > data within my testcases. Previously i was just setting a > cell with a > hard coded number within the script but found this to not > be the most > efficient method for conducting my tests. So i started to > use YAML. > Its great, it has cleaned up my scripts alot, made it > easier to change > the test data i wish to use and has forced me into > introducing a > framework, so all is good. However... > > When im trying to input specific number into a text field > that is > sourced from the testdata.yml i get the error: > > "undefined method `length' for > 4324536:Fixnum" > > Has any one come across this before, if not could some one > indicate > what im doing wrong. > > Here is the line of ruby code: > > text_field_name_WID.set(data['WidTextField']) > > Here is the line in the yml file im sourcing: > > WidTextField: 4324536 > > Thanks again guys. > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Watir General" group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~----------~----~----~----~------~----~------~--~---