[wtr-general] Is it possible to locate/set checkbox shadowed by Label For element

2015-01-08 Thread Sohail Mirza
HI,

I want to set following checkbox but it is
shadowed by Label For element. So i can't execute b.checkbox().set
method... it is giving an error. How do i set checbox in this case?

input type=checkbox id=DailySummaryCompleted class=checkbox col-lg-1
ng-pristine ng-untouched ng-valid
data-ng-model=jobReport.DailySummaryCompleted
label for=DailySummaryCompleted /label

Further, is it still valid issue? It is not possible to find the checkbox
by its label (as it appears to be comparing a Watir::Label object):
https://github.com/watir/watir-classic/issues/56

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [wtr-general] Div tag .. issue in set value

2015-01-07 Thread Sohail Mirza
I further checked, basically when click on cell .. it rendered as textarea
as following
so i got it working with following line

@browser.textarea(:index,0).when_present.set 'test'
Cheers


[image: Inline image 1]

On Wed, Jan 7, 2015 at 5:16 PM, Sohail Mirza mrz...@gmail.com wrote:

 Hi Joe,
 Struck with strange issue...
 I am trying set text in the cell of row with the following code but no
 success. There is no error for executed script but no text typed in cell
 and just got focus out from cell.


 @browser.span(:xpath,'//*[@id=dSummary]/div[2]/div/div[2]/div/div/div[2]/div[2]/div/div/div/span').when_present.click
 //This click is to make cell editable.

 @browser.div(:xpath,'//*[@id=dSummary]/div[2]/div/div[2]/div/div/div[2]/div[2]/div').flash
 // i am using xpath of the following highlighted(blue) html rendered Div.

 @browser.div(:xpath,'//*[@id=dSummary]/div[2]/div/div[2]/div/div/div[2]/div[2]/div').send_keys
 tester // i am using xpath of the following highlighted(blue) html
 rendered Div.

 *The following is rendered HTML snippet.*
 div ng-cell=
 div ng-cell-has-focus= ng-dblclick=true amp;amp; editCell()
 class=ng-scope
 div ng-edit-cell-if=!(isFocused amp;amp; true) class=ng-scope
 div class=ngCellText col1 colt1 style=word-break: break-all;
  white-space: normal; ng-class=col.colIndex()span ng-cell-text=
 class=ng-binding/span/div
 /div
  /div
 /div

 On Tue, Jan 6, 2015 at 7:19 PM, Joe Fleck joeflec...@gmail.com wrote:

 Sohail,

 Anytime.  Glad i could help.

 Joe

 On Tue, Jan 6, 2015 at 9:47 AM, Sohail Mirza mrz...@gmail.com wrote:

 Hi Joe,
 It worked actually.
 thanks you.

 On Tue, Jan 6, 2015 at 6:44 PM, Joe Fleck joeflec...@gmail.com wrote:

 Hi Sohail,

 Have you tried anything?

 This might work:
 @browser.div(:class='ng-scope ngCellElement').send_keys Test

 Thank you,
 Joe

 On Tue, Jan 6, 2015 at 9:18 AM, Sohail Mirza mrz...@gmail.com wrote:

 Hi,
 The following code is rendered for a text box. It does not have Input
 tag and it does not have type attribute.. How can i set value in it?

 div ng-cell-has-focus= ng-dblclick=true amp;amp; editCell()
 class=ng-scope ngCellElement tabindex=0

 Any help please?

  --
 --
 Before posting, please read http://watir.com/support. In short:
 search before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google
 Groups Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google
 Groups Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google
 Groups Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [wtr-general] Div tag .. issue in set value

2015-01-07 Thread Sohail Mirza
Hi Joe,
Struck with strange issue...
I am trying set text in the cell of row with the following code but no
success. There is no error for executed script but no text typed in cell
and just got focus out from cell.


@browser.span(:xpath,'//*[@id=dSummary]/div[2]/div/div[2]/div/div/div[2]/div[2]/div/div/div/span').when_present.click
//This click is to make cell editable.

@browser.div(:xpath,'//*[@id=dSummary]/div[2]/div/div[2]/div/div/div[2]/div[2]/div').flash
// i am using xpath of the following highlighted(blue) html rendered Div.

@browser.div(:xpath,'//*[@id=dSummary]/div[2]/div/div[2]/div/div/div[2]/div[2]/div').send_keys
tester // i am using xpath of the following highlighted(blue) html
rendered Div.

*The following is rendered HTML snippet.*
div ng-cell=
div ng-cell-has-focus= ng-dblclick=true amp;amp; editCell()
class=ng-scope
div ng-edit-cell-if=!(isFocused amp;amp; true) class=ng-scope
div class=ngCellText col1 colt1 style=word-break: break-all;
 white-space: normal; ng-class=col.colIndex()span ng-cell-text=
class=ng-binding/span/div
/div
 /div
/div

On Tue, Jan 6, 2015 at 7:19 PM, Joe Fleck joeflec...@gmail.com wrote:

 Sohail,

 Anytime.  Glad i could help.

 Joe

 On Tue, Jan 6, 2015 at 9:47 AM, Sohail Mirza mrz...@gmail.com wrote:

 Hi Joe,
 It worked actually.
 thanks you.

 On Tue, Jan 6, 2015 at 6:44 PM, Joe Fleck joeflec...@gmail.com wrote:

 Hi Sohail,

 Have you tried anything?

 This might work:
 @browser.div(:class='ng-scope ngCellElement').send_keys Test

 Thank you,
 Joe

 On Tue, Jan 6, 2015 at 9:18 AM, Sohail Mirza mrz...@gmail.com wrote:

 Hi,
 The following code is rendered for a text box. It does not have Input
 tag and it does not have type attribute.. How can i set value in it?

 div ng-cell-has-focus= ng-dblclick=true amp;amp; editCell()
 class=ng-scope ngCellElement tabindex=0

 Any help please?

  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google
 Groups Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google
 Groups Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[wtr-general] Div tag .. issue in set value

2015-01-06 Thread Sohail Mirza
Hi,
The following code is rendered for a text box. It does not have Input tag
and it does not have type attribute.. How can i set value in it?

div ng-cell-has-focus= ng-dblclick=true amp;amp; editCell()
class=ng-scope ngCellElement tabindex=0

Any help please?

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [wtr-general] Div tag .. issue in set value

2015-01-06 Thread Sohail Mirza
Hi Joe,
It worked actually.
thanks you.

On Tue, Jan 6, 2015 at 6:44 PM, Joe Fleck joeflec...@gmail.com wrote:

 Hi Sohail,

 Have you tried anything?

 This might work:
 @browser.div(:class='ng-scope ngCellElement').send_keys Test

 Thank you,
 Joe

 On Tue, Jan 6, 2015 at 9:18 AM, Sohail Mirza mrz...@gmail.com wrote:

 Hi,
 The following code is rendered for a text box. It does not have Input tag
 and it does not have type attribute.. How can i set value in it?

 div ng-cell-has-focus= ng-dblclick=true amp;amp; editCell()
 class=ng-scope ngCellElement tabindex=0

 Any help please?

  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [wtr-general] watir xpath how to use variable

2015-01-04 Thread Sohail Mirza
Hi,
yep you're right. i missed basic topic How to use variables inside strings
i got it and my code is working fine.



On Sat, Jan 3, 2015 at 8:00 PM, Oscar Rieken bis...@gmail.com wrote:

 I would suggest you take some time and learn how ruby works, and how to
 manage strings.

 On Fri, Jan 2, 2015 at 10:23 AM, Sohail Mirza mrz...@gmail.com wrote:

 Hi Joe

 I am getting the following error.

 *Code:*
 $rowCount = @browser.table(:class, 'table table-hover table-condensed
 table-bordered table-striped ng-scope ng-table').rows.size
 @browser.text_field(:xpath,'/html/body/div/div[4]/div/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/tr[$rowCount-2]/td[1]/input[1]').when_present.set
 'w1'

 puts $rowCount // This print 6. if i inspect the last row and copy xpath

 *xpath:*

 /html/body/div/div[4]/div/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/
 *tr[4]*/td[1]/input[1]

 so, i just replaced xpath as following 


 /html/body/div/div[4]/div/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/
 *tr[4]*/td[1]/input[1]

 /html/body/div/div[4]/div/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/
 *tr[$rowCount-2*]/td[1]/input[1]')

 Note: my table has 6 rows .. 2 rows are being considered from header.

 *Error*
   timed out after 30 seconds, waiting for
 {:xpath=/html/body/div/div[4]/di
 v/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/tr*[$rowCount-2*
 ]/td[1]/in
 put[1], :tag_name=input or textarea, :type=(any text type)} to
 become pre
 sent (Watir::Wait::TimeoutError)
   ./features/step_definitions/ManageConsumables.rb:23:in `/^I enter
 required
  information$/'
   features\ManageConsumables.feature:4:in `When I enter required
 information

 On Wed, Dec 31, 2014 at 9:14 PM, Joe Fleck joeflec...@gmail.com wrote:

 Hi,

 What is the error you are receiving?

 Joe
 On Dec 31, 2014 4:08 AM, Sohail Mirza mrz...@gmail.com wrote:

 Can we use variable for XPath property?

 The following line of codes failing

 $rowCount = @browser.table(:class, 'table table-hover table-condensed
 table-bordered table-striped ng-scope ng-table').rows.size


 @browser.text_field(:xpath,'/html/body/div/div[4]/div/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/
 tr[*$rowCount*-2]/td[1]/input[1]').when_present.set 'test'

 Any comments?

  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google
 Groups Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.

  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google
 Groups Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [wtr-general] watir xpath how to use variable

2015-01-02 Thread Sohail Mirza
Hi Joe

I am getting the following error.

*Code:*
$rowCount = @browser.table(:class, 'table table-hover table-condensed
table-bordered table-striped ng-scope ng-table').rows.size
@browser.text_field(:xpath,'/html/body/div/div[4]/div/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/tr[$rowCount-2]/td[1]/input[1]').when_present.set
'w1'

puts $rowCount // This print 6. if i inspect the last row and copy xpath

*xpath:*
/html/body/div/div[4]/div/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/
*tr[4]*/td[1]/input[1]

so, i just replaced xpath as following 

/html/body/div/div[4]/div/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/
*tr[4]*/td[1]/input[1]
/html/body/div/div[4]/div/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/
*tr[$rowCount-2*]/td[1]/input[1]')

Note: my table has 6 rows .. 2 rows are being considered from header.

*Error*
  timed out after 30 seconds, waiting for
{:xpath=/html/body/div/div[4]/di
v/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/tr*[$rowCount-2*
]/td[1]/in
put[1], :tag_name=input or textarea, :type=(any text type)} to
become pre
sent (Watir::Wait::TimeoutError)
  ./features/step_definitions/ManageConsumables.rb:23:in `/^I enter
required
 information$/'
  features\ManageConsumables.feature:4:in `When I enter required
information

On Wed, Dec 31, 2014 at 9:14 PM, Joe Fleck joeflec...@gmail.com wrote:

 Hi,

 What is the error you are receiving?

 Joe
 On Dec 31, 2014 4:08 AM, Sohail Mirza mrz...@gmail.com wrote:

 Can we use variable for XPath property?

 The following line of codes failing

 $rowCount = @browser.table(:class, 'table table-hover table-condensed
 table-bordered table-striped ng-scope ng-table').rows.size


 @browser.text_field(:xpath,'/html/body/div/div[4]/div/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/
 tr[*$rowCount*-2]/td[1]/input[1]').when_present.set 'test'

 Any comments?

  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.

  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/d/optout.


-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[wtr-general] watir xpath how to use variable

2014-12-31 Thread Sohail Mirza
Can we use variable for XPath property?

The following line of codes failing

$rowCount = @browser.table(:class, 'table table-hover table-condensed
table-bordered table-striped ng-scope ng-table').rows.size


@browser.text_field(:xpath,'/html/body/div/div[4]/div/div[2]/div/lookup-grid/div/div/div[1]/div/table/tbody/
tr[*$rowCount*-2]/td[1]/input[1]').when_present.set 'test'

Any comments?

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[wtr-general] Re: Nested Div/Spans element..How to select it?

2014-12-29 Thread Sohail Mirza
Hi,
I am able to resolve it using following two lines.
  @browser.span(:text,'').click   // Click on list to expand it.
  @browser.div(:text,'').click //click on element to select it.

I hope this is nice way.
Any suggestion from experts?


On Mon, Dec 29, 2014 at 3:32 PM, Sohail Mirza mrz...@gmail.com wrote:

 *Hi,*
 I have following complex HTML code rendered for select list (not drop
 down).. developer used Div  span tags to make it look alike drop down with
 values populated
 My requirement is to select value Test 1 (showing in below code). I did
 what i can do but not able to select it.
 Any suggestion please?

 *HTML Rendered Code:*

 div class=form-group ng-class={ 'has-error' :
 TestFrom.TestType.$invalid amp;amp; (TestFrom.TestType.$touched||
 TestFrom.$submitted) }
 label for=TestType class=control-labelTest
 Type/label
 div
 div class=select2 select2-container ng-valid
 ng-dirty ng-valid-parse select2-container-active select2-dropdown-open
 ng-class={'select2-container-active select2-dropdown-open': $select.open,
 'select2-container-disabled': $select.disabled,
 'select2-container-active': $select.focus,
 'select2-allowclear': $select.allowClear amp;amp;
 !$select.isEmpty()} id=TestType name=TestType
 ng-model=TestType.selected theme=select2 ng-disabled=disabled
 style=min-width: 200px;a class=select2-choice ui-select-match
 ng-class={'select2-default': $select.isEmpty()}
 ng-click=$select.activate() placeholder=Select Test Typespan
 ng-show=$select.isEmpty() class=select2-chosen ng-binding
 ng-hideSelect Test Type/span span ng-hide=$select.isEmpty()
 class=select2-chosen ng-transclude=span class=ng-binding
 ng-scopeExploration
 /spanbutton id=btnTestTypeClear
 name=btnTestTypeClear style=background:none;border:none;cursor:pointer;
 padding:5px 10px; position:absolute; right:10px; top:-5px;
 ng-click=clear($event) class=ng-scopex/button
 /span
 span class=select2-arrow ui-select-toggle
 ng-click=$select.toggle($event)b/b/span/adiv
 class=select2-drop select2-with-searchbox select2-drop-active
 ng-class={'select2-display-none': !$select.open}div
 class=select2-search ng-show=$select.searchEnabledinput type=text
 autocomplete=off autocorrect=off autocapitalize=off
 spellcheck=false class=ui-select-search select2-input ng-pristine
 ng-valid ng-touched ng-model=$select.search/divul
 class=ui-select-choices ui-select-choices-content select2-results
 ng-scope repeat=TestType in TestTypes | propsFilter: {Name:
 $select.search}li class=ui-select-choices-group
 ng-class={'select2-result-with-children': $select.isGrouped}div
 ng-show=$select.isGrouped class=ui-select-choices-group-label
 select2-result-label ng-binding ng-hide ng-bind-html=$group.name/divul
 ng-class={'select2-result-sub': $select.isGrouped,
 'select2-result-single': !$select.isGrouped}
 class=select2-result-single!-- ngRepeat: TestType in $select.items
 --!-- ngIf: $select.open --li class=ui-select-choices-row ng-scope
 select2-highlighted ng-class={'select2-highlighted':
 $select.isActive(this), 'select2-disabled': $select.isDisabled(this)}
 ng-repeat=TestType in $select.items ng-if=$select.open
 ng-mouseenter=$select.setActiveItem(TestType)
 ng-click=$select.select(TestType,false,$event)div
 class=select2-result-label ui-select-choices-row-inner
 uis-transclude-append=
 div ng-bind-html=TestType.Name | highlight:
 $select.search class=ng-binding ng-scope*Test 1*/div
 /div/li

 
 --
 -




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[wtr-general] checkbox set issue.

2014-12-28 Thread Sohail Mirza
Hi,
I am trying to set the checkbox. The rendered htmkl code is as following.
class should not an option since there are 5 other checkboxed with same
class property value.
Can i set this checkbox using span element?
Any suggestions please.

span data-ng-class=node.selected
data-ng-click=abc.selectNodeLabel(node) class=ng-binding
input type=checkbox ng-disabled=!node.Enable ng-model=node.Checked
class=ng-valid ng-dirty ng-valid-parse ng-touched
   All Students
/span

Regards,

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[wtr-general] Span element

2014-11-28 Thread Sohail Mirza
Hi,

I am trying to perform click event on the following span element but
something not working for me.

ul class=ng-scope data-ng-repeat=module in leftSideNavigation
li data-ng-click=selectedNode(module)
a href=/home ui-sref=home
* span class=ng-binding*
* Mobile amp; Accessories*
* /span*
/a
/li
/ul


I not sure how to access li in my code since it does not have rendered
attribute. Any help?
Browser.ul().li().span().click 

thanks

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[wtr-general] Re: Span element

2014-11-28 Thread Sohail Mirza
Well, i got solution using following line of code.
browser.link(:text = *Mobile  Accessories*).click

Just wanted to ask, is it the only way or could be some other nice way?
Thanks

On Fri, Nov 28, 2014 at 5:13 AM, Sohail Mirza mrz...@gmail.com wrote:

 Hi,

 I am trying to perform click event on the following span element but
 something not working for me.

 ul class=ng-scope data-ng-repeat=module in leftSideNavigation
 li data-ng-click=selectedNode(module)
 a href=/home ui-sref=home
 * span class=ng-binding*
 * Mobile amp; Accessories*
 * /span*
 /a
 /li
 /ul


 I not sure how to access li in my code since it does not have rendered
 attribute. Any help?
 Browser.ul().li().span().click 

 thanks


-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[wtr-general] how to check TextArea is enabled or disabled

2013-06-19 Thread Sohail Mirza
Hi,

Is there any method available using which i can check whether the textarea
is enabled or disabled.

i checked the following
http://rdoc.info/gems/watir-webdriver/Watir/TextArea

but could not find enabled? method.

Please suggest

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] how to check TextArea is enabled or disabled

2013-06-19 Thread Sohail Mirza
okay i try it.
but question...i am asking for text_area but you mentioned for text_field.
if it will work then how because both are difference objects.




On Wed, Jun 19, 2013 at 3:31 PM, Željko Filipin zeljko.fili...@gmail.comwrote:

 On Wed, Jun 19, 2013 at 1:20 PM, Sohail Mirza mrz...@gmail.com wrote:

 Is there any method available using which i can check whether the
 textarea is enabled or disabled.


 Watir::Input has #enabled? method:


 http://rdoc.info/gems/watir-webdriver/Watir/Input#enabled%3F-instance_method

 You should just try it:

 browser.text_field.enabled?

  Željko
 --
 https://leanpub.com/watirbook

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] how to check TextArea is enabled or disabled

2013-06-19 Thread Sohail Mirza
unfortunately it is not working

*NoMethodError: undefined method `enabled?' for #Watir::TextArea:0x2fb0350
*

C:/Ruby193/lib/ruby/gems/1.9.1/gems/watir-webdriver-0.6.4/lib/watir-webdrive
r/elements/element.rb:553:in `method_missing'



On Wed, Jun 19, 2013 at 3:43 PM, Željko Filipin zeljko.fili...@gmail.comwrote:

 On Wed, Jun 19, 2013 at 1:41 PM, Sohail Mirza mrz...@gmail.com wrote:

 i am asking for text_area but you mentioned for text_field. if it will
 work then how because both are difference objects.


 That was my mistake, I did not notice you were talking about text area. :)
 It _should_ work the same as text field, but the easiest way to find out is
 just to try it.

 Željko

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] Re: Watir-Webdriver Installation Issue

2013-05-09 Thread Sohail Mirza
Zelijko, noted your suggestion.

Now i am getting the following error
*
*
*irb(main):002:0 require watir-webdriver*
= true
*irb(main):003:0 browser=Watir::Browser.new:chrome*
Started ChromeDriver
port=9515
version=0.8
log=C:\devkit\chromedriver.log
You are using an old or stdlib version of json gem
Please upgrade to the recent version by adding this to your Gemfile:

  gem 'json', '~ 1.7.7'

= #Watir::Browser:0x..f9d78e6aa url={message=no such session: url\n
 (Driv
er info: chromedriver=0.8,platform=Windows NT 6.1 x86_64)}
title={message=n
o such session: title\n  (Driver info: chromedriver=0.8,platform=Windows NT
6.1
x86_64)}
irb(main):004:0


On Thu, May 9, 2013 at 12:47 PM, Sohail Mirza mrz...@gmail.com wrote:

 Hi,

 I am trying to install Watir-Webdriver and try to work on it but getting
 the following error :(

 [image: Inline image 1]

 Any comments please.



-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


image.png

[wtr-general] Re: Watir-Webdriver Installation Issue

2013-05-09 Thread Sohail Mirza
I do understand the error message hopefully in correct way.
but when i run gem update command it says me that Nothing to update.
All gems are updated.

I have ruby 1.9.3. 3p392

what i am missing here


On Thu, May 9, 2013 at 2:05 PM, Sohail Mirza mrz...@gmail.com wrote:

 Zelijko, noted your suggestion.

 Now i am getting the following error
 *
 *
 *irb(main):002:0 require watir-webdriver*
 = true
 *irb(main):003:0 browser=Watir::Browser.new:chrome*
 Started ChromeDriver
 port=9515
 version=0.8
 log=C:\devkit\chromedriver.log
 You are using an old or stdlib version of json gem
 Please upgrade to the recent version by adding this to your Gemfile:

   gem 'json', '~ 1.7.7'

 = #Watir::Browser:0x..f9d78e6aa url={message=no such session: url\n
  (Driv
 er info: chromedriver=0.8,platform=Windows NT 6.1 x86_64)}
 title={message=n
 o such session: title\n  (Driver info: chromedriver=0.8,platform=Windows
 NT 6.1
 x86_64)}
 irb(main):004:0


 On Thu, May 9, 2013 at 12:47 PM, Sohail Mirza mrz...@gmail.com wrote:

 Hi,

 I am trying to install Watir-Webdriver and try to work on it but getting
 the following error :(

 [image: Inline image 1]

 Any comments please.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


image.png

Re: [wtr-general] Re: Watir-Webdriver Installation Issue

2013-05-09 Thread Sohail Mirza
even this is not working.
i just learnt from chromdriver download page that Chrome Driver is not
available for WIN 64 bit operating system. :( is it true?
i think my OS is 64 bit and that is causing problem since chrome driver is
32 bit compatible



On Thu, May 9, 2013 at 3:33 PM, Željko Filipin zeljko.fili...@gmail.comwrote:

 On Thu, May 9, 2013 at 12:05 PM, Sohail Mirza mrz...@gmail.com wrote:

 You are using an old or stdlib version of json gem
 Please upgrade to the recent version by adding this to your Gemfile:
   gem 'json', '~ 1.7.7'


 I think you should explicitly install json gem:

 gem install json

 Željko

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] data-bind=value: UserName

2013-04-29 Thread Sohail Mirza
Hi,

In the following rendered HTML code, can i use Value attribute to set value
into the user name field? like as follow

*Browser.text_field(:value,UserName).set Hi*

input type=text data-bind=value: UserName class=input-block-level
placeholder=User Name

kindly advise.
Thanks

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] how to call script within script

2013-03-26 Thread Sohail Mirza
i meant how can i call a script into another script.
i have login.rb script ready and i want to call it into another script
AddCustomer.rb on top. how to do it? i am using Test-Unit framework.



On Tue, Mar 26, 2013 at 5:22 PM, Željko Filipin zeljko.fili...@gmail.comwrote:

 On Tue, Mar 26, 2013 at 2:19 PM, Sohail Mirza mrz...@gmail.com wrote:

 i am trying with load 'Test.rb' but it is not loading


 My mind reading machine is not working at the moment. Could you provide
 more information, like the code that you have tried and error messages?

 Željko
 --
 https://leanpub.com/watirbook

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] how to call script within script

2013-03-26 Thread Sohail Mirza
i have one common script Browser.rb which is used to initialize and open my
web application in chrome browser. i called it once in my main script
(AddCustomer.rb) and it opens browser and go to required url. In my
Browser.rb script i initialized as follow

*  def setup*
*@browser = Watir::Browser.new:chrome *
*@browser.goto (http://testserver:8080/;)  #The URL should come from
the excel file.*
*@browser.window.maximize*

*  end*

The problem is that variable *@browser *does not work for other scripts
which i am calling in my main script (AddCustomer.rb) and hence object are
identifiable. *how can i resolve this issue?*
*Please advise.*
*
*

On Tue, Mar 26, 2013 at 6:03 PM, Oscar Rieken bis...@gmail.com wrote:

 I would also suggest picking up the ruby pickaxe book
 http://pragprog.com/book/ruby4/programming-ruby-1-9-2-0

 http://mislav.uniqpath.com/poignant-guide/

  and actually learning ruby here are a few places that may help as well
 http://tryruby.org/levels/1/challenges/0(free)

 http://www.codeschool.com/
 http://www.codecademy.com/ (free)




 On Tue, Mar 26, 2013 at 9:37 AM, Željko Filipin 
 zeljko.fili...@gmail.comwrote:

 On Tue, Mar 26, 2013 at 2:32 PM, Sohail Mirza mrz...@gmail.com wrote:

 i meant how can i call a script into another script.


 require is what you are looking for:

 http://rubylearning.com/satishtalim/including_other_files_in_ruby.html

 Željko

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] New to Ruby and Watir

2013-03-25 Thread Sohail Mirza
Hi Chuck van der Linden,
*
*
I have question for you *How would rate Watir Test-Unit framework? *In
your detailed reply you did not mention Test_Unit Framework? you dont like
or it has limitation..
i am asking so because i am currently using it and found it good.
please comment.
*
*
Thanks,
*
*
On Mon, Mar 25, 2013 at 8:21 PM, Chuck van der Linden 
cvanderlin...@climate.com wrote:

 On Monday, March 25, 2013 5:26:32 AM UTC-7, j-f...@sbcglobal.net wrote:

 Akiaa,

 Here is a good starting point.
 https://github.com/watir/**watir/blob/master/README.mdhttps://github.com/watir/watir/blob/master/README.md

 Regards,

 Joseph Fleck

 If your actions inspire others to dream more,
 learn more, do more and become more,
 you are a leader.
 John Quincy Adams

 If you are just doing a simple proof of concept, and leaning to do some
 basic watir scripting, then you can just create your scripts as an RB file
 and execute them.

 But once you get past the point of the basics, you will really want some
 kind of framework within which to run your tests. This can make it easier
 to run groups of tests, or a specific test, and also deal with issues like
 reporting results, and making it easier to automate the running of the test
 automation

  There are a number of good choices, but offhand I'd say two of the more
 popular ones are rspec and cucumber.  There are good books on both
 frameworks from Pragmatic Programmers, but neither specifically addresses
 using the frameworks with watir.. (still, I'd recommend reading the one
 that is applicable if you choose one of those as a framework)

 There was a good training session held last year at the Test Automation
 Bazaar on using Cucumber, Watir, and the Page-Objects gem, you can find a
 recording of it via this page.
 https://github.com/watir/watir-bazaar/wiki/Test-Automation-Workshop-2012 
 apologies for the quality of the recording, you can blame that on me.

 Other good starting resources are:
  1)  the Watir-Book  See the readme on this page
 https://github.com/watir/watirbook for more info
  2) Jeff Cheesy Morgan's Cucumber and Cheese book
 https://leanpub.com/cucumber_and_cheese

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Re: problem

2013-03-21 Thread Sohail Mirza
Hi All,

Thanks for the comments. However, i have solved the problem as follow
*@browser.a(:text,Customer Lines).fire_event(onclick)*

it is perfectly running for me.
But one thing which i am still figuring out is why it did not work for
simple Click method and why it worked with fire_event(onClick)?

Thanks,

On Thu, Mar 21, 2013 at 3:14 AM, Chuck van der Linden 
cvanderlin...@climate.com wrote:

 On Wednesday, March 20, 2013 4:33:55 AM UTC-7, mc060200778 wrote:

 Hi,

 i am facing problem in automating the following HTML code

 a href=#divCustomerLinesTab data-toggle=tabCustomer Linesspan
 class=tabLoading id=divCustomerLinesTabTab style=display:
 inline;/span/a

 I am using the following lines but NOTHING IS working for me :( please
 help  advise

 @browser.span(:class,**tabLoading).click
 *@browser.link(:href,http://TestApp:8080/CustomerManagement/;).click*
 *@browser.a(:text,CustomerLines).click*
 *
 *


 Firstly, actual 'results' for each of those --especially if it's an error
 message, but even if it's 'nothing got clicked and the script kept
 running'-- are really really helpful to the people you are asking to assist
 you.

 Secondly lets look at each of your items in turn.

 @browser.span(:class,**tabLoading).click

 Presuming for a moment this did not give an error, and that there is but
 one single span in the entire page with this class, then you might try
 clicking the parent. Given that the span had an ID that did not appear to
 be randomly generated, I'd suggest using that instead, since they are
 supposed to be unique on the page, to identify the element you want

 @browser.span(:id = divCustomerLinesTabTab).click
 or maybe try clicking it's parent, a link, something more commonly clicked

 @browser.span(:id = divCustomerLinesTabTab).parent.click

 Next you tried

 @browser.link(:href,http://**TestApp:8080/**CustomerManagement/http://testapp:8080/CustomerManagement/
 ).click
 *
 *
 I don't generally use the entire URL when selecting by href because it
 will change if your test env changes. Either go for a partial match using a
 portion of the url as a regex, or use something else like the link text
 (presuming you don't expect that to change often) However in this case,
 the href given is nothing like the value you supplied, so I would expect it
 to generate an error that it could not locate the object. If you want to
 select that by href, then your code should have looked more like this

 @browser.link(:href = #divCustomerLinesTab).click

 Next you had this, trying to click the anchor tag (link) by the text
 *
 *
 @browser.a(:text,**CustomerLines).click
 *
 *
 This is another thing I'd expect to generate a not found error, since the
 link text you give above, does not match the HTML you gave. Presuming the
 HTML is right, you should be using something like this (I use 'link'
 instead of the tag name 'a' since a lot of folks think of anchor tags as
 'links' and for me anyway I feel it's more readable code.

 @browser.link(:text = **Customer Lines).click

 A good way to test this stuff out is to use IRB, and try out the commands
 against the browser that way. Using the .flash method first (as Super Kevy
 showed hin his answer) is a good way to see if you are really locating the
 thing you think you are.

  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Re: how to click button from nested divs

2013-03-21 Thread Sohail Mirza
Still it is not working for me.
The script execution continues successfully giving a perception that button
has been clicked but the button is not clicked infact.

in rendered html code, i found this button nested in my Div (almost 8th
child div), can it be the reason of subject problem?



On Thu, Mar 21, 2013 at 2:48 AM, Chuck van der Linden 
cvanderlin...@climate.com wrote:

 On Wednesday, March 20, 2013 6:24:09 AM UTC-7, richdownie wrote:

 Have you tried waiting for the element?

 http://watirwebdriver.com/**waiting/ http://watirwebdriver.com/waiting/


 That's pretty much what I would have suggested, especially if this is a
 page with a lot of ajax type operations, you may need to wait a tiny bit
 for the button to be in the proper state, especially if there is client
 side code that is examining and validating the values filled in on the form
 you are about to submit.

 I'd start with something like this

 @browser.button(:id, btnAddNewCustomer).when_present.click

 If that does not work, much as I hate to suggest it, you might need a
 fixed sleep right before the button click

 sleep 1
 @browser.button(:id, btnAddNewCustomer).click




 On Wed, Mar 20, 2013 at 7:36 AM, Sohail Mirza mrz...@gmail.com wrote:

 Finally i am able to resolve it but it works sometime and sometime it
 does not work
 *@browser.input(:value=Create New Customer).click*

 please advise another convenient way to handle it?
 Thanks,



 On Tue, Mar 19, 2013 at 6:36 PM, Sohail Mirza mrz...@gmail.com wrote:

 No Success Alex. Sorry

 On Tue, Mar 19, 2013 at 5:22 PM, Alex Shtayer asht...@gmail.comwrote:

 I don't think that problem in fact that div is nested, but more that
 click event is not working as it should

 Try

 browser.button(:id, *btnAddNewCustomer*).fire_**event(onclick)
 or
 browser.button(:id, *btnAddNewCustomer*).fire_**event(onmousedown)
 or
 browser.button(:id, *btnAddNewCustomer*).send_keys :enter
 or
 browser.button(:id, *btnAddNewCustomer*).click
 browser.button(:id, *btnAddNewCustomer*).click
 to see whether problem in click action

 --
 --
 Before posting, please read http://watir.com/support. In short:
 search before you ask, be nice.

 watir-...@googlegroups.com
 http://groups.google.com/**group/watir-generalhttp://groups.google.com/group/watir-general
 watir-genera...@**googlegroups.com


 ---
 You received this message because you are subscribed to the Google
 Groups Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to watir-genera...@**googlegroups.com.

 For more options, visit 
 https://groups.google.com/**groups/opt_outhttps://groups.google.com/groups/opt_out
 .





  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-...@googlegroups.com
 http://groups.google.com/**group/watir-generalhttp://groups.google.com/group/watir-general
 watir-genera...@**googlegroups.com


 ---
 You received this message because you are subscribed to the Google
 Groups Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to watir-genera...@**googlegroups.com.

 For more options, visit 
 https://groups.google.com/**groups/opt_outhttps://groups.google.com/groups/opt_out
 .






 --
 http://www.richdownie.com
 http://github.com/richdownie

  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] Watir Webdriver Logger

2013-03-20 Thread Sohail Mirza
Hi,

I am curious to know about Logger.rb.
Can i use it in watir webdriver?
Where i can find more about it?
Can someone share simple example?

Thanks

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Watir Webdriver Logger

2013-03-20 Thread Sohail Mirza
Are you talking about the following home page?
http://wiki.openqa.org/display/WTR/Example+Logging

please share logger home page link.
Thanks

On Wed, Mar 20, 2013 at 1:41 PM, Željko Filipin zeljko.fili...@gmail.comwrote:

 On Wed, Mar 20, 2013 at 10:39 AM, Sohail Mirza mrz...@gmail.com wrote:

 I am curious to know about Logger.rb.


 I am too. :) Can you link to it's home page?

 Željko
 --
 https://leanpub.com/watirbook

  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Watir Webdriver Logger

2013-03-20 Thread Sohail Mirza
so i guess logger does not work with Watir Webdriver ...
Can you suggest any other way around for logging the details ? one way
which i know / found is to Test.rb  test.txt
is that the only way? Which one are using?


On Wed, Mar 20, 2013 at 1:52 PM, Željko Filipin zeljko.fili...@gmail.comwrote:

 On Wed, Mar 20, 2013 at 10:49 AM, Sohail Mirza mrz...@gmail.com wrote:

 Are you talking about the following home page?
 http://wiki.openqa.org/display/WTR/Example+Logging


 I am not talking about anything. I have asked what _you_ are talking
 about. :)

 The page that you have linked to was last updated in 2008. Do the math
 yourself. My guess is that any information there is out of date.

 Željko

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Watir Webdriver Logger

2013-03-20 Thread Sohail Mirza
okay i explain the context
I want to record each step details in somewhere notepad file.
For example whatever my script do , that should be recorded / logged
in separate file with simplified details

@browser = Watir::Browser.new :chrome
@browser.goto (http://testapp:8080/;)

should be recorded / outputted / logged as
Opening browser page with specified URL

I hope you get my point?
Thanks

On Wed, Mar 20, 2013 at 2:04 PM, Željko Filipin zeljko.fili...@gmail.comwrote:

 On Wed, Mar 20, 2013 at 11:03 AM, Sohail Mirza mrz...@gmail.com wrote:

 Can you suggest any other way around for logging the details ?


 I need more context. What is the problem you are trying to solve?

 Željko

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] problem

2013-03-20 Thread Sohail Mirza
Hi,

i am facing problem in automating the following HTML code

a href=#divCustomerLinesTab data-toggle=tabCustomer Linesspan
class=tabLoading id=divCustomerLinesTabTab style=display:
inline;/span/a

I am using the following lines but NOTHING IS working for me :( please help
 advise

@browser.span(:class,tabLoading).click
*@browser.link(:href,http://TestApp:8080/CustomerManagement/;).click*
*@browser.a(:text,CustomerLines).click*
*
*
Thanks,
*
*

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Re: how to click button from nested divs

2013-03-20 Thread Sohail Mirza
Finally i am able to resolve it but it works sometime and sometime it does
not work
*@browser.input(:value=Create New Customer).click*

please advise another convenient way to handle it?
Thanks,



On Tue, Mar 19, 2013 at 6:36 PM, Sohail Mirza mrz...@gmail.com wrote:

 No Success Alex. Sorry

 On Tue, Mar 19, 2013 at 5:22 PM, Alex Shtayer ashta...@gmail.com wrote:

 I don't think that problem in fact that div is nested, but more that
 click event is not working as it should

 Try

 browser.button(:id, *btnAddNewCustomer*).fire_event(onclick)
 or
 browser.button(:id, *btnAddNewCustomer*).fire_event(onmousedown)
 or
 browser.button(:id, *btnAddNewCustomer*).send_keys :enter
 or
 browser.button(:id, *btnAddNewCustomer*).click
 browser.button(:id, *btnAddNewCustomer*).click
 to see whether problem in click action

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.






-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] how to click button from nested divs

2013-03-19 Thread Sohail Mirza
Hi,

i would like to know how to perform button click from nested div's when it
is nested upto seventh div or more
*input id=btnAddNewCustomer type=submit class=ui-button Action
value=Create New Customer onclick=createNewCustomer()*
*
*

Currently, the script execution neither gives an error nor click the
button. it just moves on the next statement execution.
kindly advise.

Thanks
*
*

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Re: how to click button from nested divs

2013-03-19 Thread Sohail Mirza
No Success Alex. Sorry

On Tue, Mar 19, 2013 at 5:22 PM, Alex Shtayer ashta...@gmail.com wrote:

 I don't think that problem in fact that div is nested, but more that click
 event is not working as it should

 Try

 browser.button(:id, *btnAddNewCustomer*).fire_event(onclick)
 or
 browser.button(:id, *btnAddNewCustomer*).fire_event(onmousedown)
 or
 browser.button(:id, *btnAddNewCustomer*).send_keys :enter
 or
 browser.button(:id, *btnAddNewCustomer*).click
 browser.button(:id, *btnAddNewCustomer*).click
 to see whether problem in click action

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] how disable javascript alert

2013-03-19 Thread Sohail Mirza
Hi,

Can someone explain how to disable Java Script Alert message during watir
script execution?
Thanks

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] Re: how disable javascript alert

2013-03-19 Thread Sohail Mirza
This thread is closed. The information is available at following link
*http://watirwebdriver.com/javascript-dialogs/*


On Tue, Mar 19, 2013 at 6:42 PM, Sohail Mirza mrz...@gmail.com wrote:

 Hi,

 Can someone explain how to disable Java Script Alert message during watir
 script execution?
 Thanks



-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] Element is not clickable at point

2013-03-18 Thread Sohail Mirza
Hi,

I am getting this error Element is not clickable at point.
The script is to click Button which is showing but under another container
.


i am using watir-webdriver
kindly comment as i am struck

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] Watir Webdriver Zoom

2013-03-18 Thread Sohail Mirza
Hi

strange behavior

when web application is accessed using watir script its opening with
default zoom in (high zooom and UI looks bigger icon and buttons etc)
however if the application open normally it is opening with actual/required
zoom

Why its happening and how to stop it?

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] How to zoom out web app using watir

2013-03-18 Thread Sohail Mirza
hi,

how to zoom out web application using watir? my manual actions are Ctrl +
scroll down
how i can achieve this using watir-webdriver

Kindly comment. Thanks

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Re: Element is not clickable at point

2013-03-18 Thread Sohail Mirza
*i get the following error when using fire_event(onclick) *

function(){return function(){var l=this;
function m(a){var c=typeof a;if(c==object)if(a){if(a instanceof
Array)returna
rray;else if(a instanceof Object)return c;var
b=Object.prototype.toString.call(
a);if(b==[object Window])returnobject;if(b==[object Array]||typeof
a.lengt
h==numbertypeof a.splice!=undefinedtypeof
a.propertyIsEnumerable!=undef
ined!a.propertyIsEnumerable(splice))returnarray;if(b==[object
Function]
||typeof a.call!=undefinedtypeof a.propertyIsEnumerable!=undefined!
a.pro
pertyIsEnumerable(call))returnfunction}else returnnull;else if(c==
functiontypeof a.call==undefined)returnobject;return c}function
n(a,c){f
unction b(){}b.prototype=c.prototype;a.i=c.prototype;a.prototype=new
b};function
 o(a){this.stack=Error().stack||;if(a)this.message=String(a)}n(o,Error);functi
on aa(a){for(var c=1;carguments.length;c++){var
b=String(arguments[c]).replace(
/\$/g,);a=a.replace(/\%s/,b)}return a}
function p(a,c){var
b=0,d=String(a).replace(/^[\s\xa0]+|[\s\xa0]+$/g,).split(
.),f=String(c).replace(/^[\s\xa0]+|[\s\xa0]+$/g,).split(.),k=Math.max(d.len
gth,f.length);for(var j=0;b==0jk;j++){var
e=d[j]||,g=f[j]||,q=RegExp((\\
d*)(\\D*),g),s=RegExp((\\d*)(\\D*),g);do{var
h=q.exec(e)||[,,],i=s.
exec(g)||[,,];if(h[0].length==0i[0].length==0)break;b=r(h[1].length==0?0
:parseInt(h[1],10),i[1].length==0?0:parseInt(i[1],10))||r(h[2].length==0,i[2].le
ngth==0)||r(h[2],i[2])}while(b==
0)}return b}function r(a,c){if(ac)return-1;else if(ac)return 1;return
0};funct
ion
t(a,c){c.unshift(a);o.call(this,aa.apply(null,c));c.shift();this.l=a}n(t,o);
function ba(a,c){if(!a){var
b=Array.prototype.slice.call(arguments,2),d=Asserti
on failed;if(c){d+=: +c;var f=b}throw new t(+d,f||[]);}return a};var
u=Arra
y.prototype,ca=u.indexOf?function(a,c,b){ba(a.length!=null);return
u.indexOf.cal
l(a,c,b)}:function(a,c,b){b=b==null?0:b0?Math.max(0,a.length+b):b;if(typeof
a==
string){if(typeof c!=string||c.length!=1)return-1;return
a.indexOf(c,b)}for(
b=b;ba.length;b++)if(b in aa[b]===c)return b;return-1};var
v,w,x,y;function z
(){return l.navigator?l.navigator.userAgent:null}y=x=w=v=false;var
A;if(A=z()){v
ar
da=l.navigator;v=A.indexOf(Opera)==0;w=!vA.indexOf(MSIE)!=-1;x=!vA.in
dexOf(WebKit)!=-1;y=!v!xda.product==Gecko}var B=v,C=w,D=y,E=x,F;
a:{var G=,H;if(Bl.opera){var I=l.opera.version;G=typeof
I==function?I():I}
else{if(D)H=/rv\:([^\);]+)(\)|;)/;else if(C)H=/MSIE\s+([^\);]+)(\)|;)/;else
if(E
)H=/WebKit\/(\S+)/;if(H){var J=H.exec(z());G=J?J[1]:}}if(C){var
K,L=l.document
;K=L?L.documentMode:undefined;if(KparseFloat(G)){F=String(K);break
a}}F=G}var M
={};var
ea;!C||M[9]||(M[9]=p(F,9)=0);C(M[9]||(M[9]=p(F,9)=0));fu
nction
N(a,c){this.x=a!==undefined?a:0;this.y=c!==undefined?c:0}N.prototype.toSt
ring=function(){return(+this.x+, +this.y+)};function O(a){return
a?new fa(
P(a)):ea||(ea=new fa)}function P(a){return
a.nodeType==9?a:a.ownerDocument||a.do
cument}function fa(a){this.e=a||l.document||document}function ga(a){a=!E
a.e.co
mpatMode==CSS1Compat?a.e.documentElement:a.e.body;return new
N(a.scrollLeft,a.
scrollTop)};var Q=StopIterationin
l?l.StopIteration:Error(StopIteration);fun
ction ha(){}ha.prototype.next=function(){throw Q;};function
R(a,c,b,d,f){this.a=
!!c;aS(this,a,d);this.d=f!=undefined?f:this.c||0;if(this.a)this.d*=-1;this.h=!
b}n(R,ha);R.prototype.b=null;R.prototype.c=0;R.prototype.g=false;function
S(a,c,
b,d){if(a.b=c)a.c=typeof b==number?b:a.b.nodeType!=1?0:a.a?-1:1;if(typeof
d==
number)a.d=d}
R.prototype.next=function(){var
a;if(this.g){if(!this.b||this.hthis.d==0)throw
 Q;a=this.b;var c=this.a?-1:1;if(this.c==c){var
b=this.a?a.lastChild:a.firstChil
d;b?S(this,b):S(this,a,c*-1)}else(b=this.a?a.previousSibling:a.nextSibling)?S(th
is,b):S(this,a.parentNode,c*-1);this.d+=this.c*(this.a?-1:1)}else
this.g=true;a=
this.b;if(!this.b)throw Q;return a};
R.prototype.splice=function(){var
a=this.b,c=this.a?1:-1;if(this.c==c){this.c=c*
-1;this.d+=this.c*(this.a?-1:1)}this.a=!this.a;R.prototype.next.call(this);this.
a=!this.a;c=arguments[0];var b=m(c);c=b==array||b==objecttypeof
c.length==
number?arguments[0]:arguments;for(b=c.length-1;b=0;b--)a.parentNodea.parent
Node.insertBefore(c[b],a.nextSibling);aa.parentNodea.parentNode.removeChild(
a)};function
T(a,c,b,d){R.call(this,a,c,b,null,d)}n(T,R);T.prototype.next=functi
on(){do T.i.next.call(this);while(this.c==-1);return this.b};function
U(a,c){var
 b;a:{b=P(a);if(b.defaultViewb.defaultView.getComputedStyle)if(b=b.defaultView
.getComputedStyle(a,null)){b=b[c]||b.getPropertyValue(c);break
a}b=}return b||
(a.currentStyle?a.currentStyle[c]:null)||a.style[c]}function ia(a){var
c=a.getBo
undingClientRect();if(C){a=a.ownerDocument;c.left-=a.documentElement.clientLeft+
a.body.clientLeft;c.top-=a.documentElement.clientTop+a.body.clientTop}return
c}
function ja(a){if(C)return a.offsetParent;var
c=P(a),b=U(a,position),d=b==fix
ed||b==absolute;for(a=a.parentNode;aa!=c;a=a.parentNode){b=U(a,position);

Re: [wtr-general] Element is not clickable at point

2013-03-18 Thread Sohail Mirza
*HTML code*
input id=btnAddNewCustomer type=submit class=ui-button Action
value=Create New Customer onclick=createNewCustomer()

*RubyCode*
@browser.button(:value = Create New Customer).fire_event(onclick)



On Mon, Mar 18, 2013 at 5:28 PM, Željko Filipin zeljko.fili...@gmail.comwrote:

 On Mon, Mar 18, 2013 at 9:40 AM, Sohail Mirza mrz...@gmail.com wrote:

 I am getting this error Element is not clickable at point.


 Please share relevant HTML and Ruby code. Full text of the error, too.

 Željko
 --
 https://leanpub.com/watirbook

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Element is not clickable at point

2013-03-18 Thread Sohail Mirza
one more statement of error message
* An open modal dialog blocked the operation*

i guess the following line is causing the problem
@browser.alert.ok




On Mon, Mar 18, 2013 at 5:42 PM, Željko Filipin zeljko.fili...@gmail.comwrote:

 On Mon, Mar 18, 2013 at 2:40 PM, Sohail Mirza mrz...@gmail.com wrote:

 input id=btnAddNewCustomer type=submit class=ui-button Action
 value=Create New Customer onclick=createNewCustomer()


 Can you post a link to the page where the problem is reproducible?

 Željko

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Element is not clickable at point

2013-03-18 Thread Sohail Mirza
currently the page is accessible only in my network and not on internet
just pasting the last lines of the error

Z=Z[$]?Z[$]:Z[$]={};; return
this._.apply(null,arguments);}.apply({navigator:typ
eof window!='undefined'?window.navigator:null}, arguments);}
).apply(null, arguments);



On Mon, Mar 18, 2013 at 5:42 PM, Željko Filipin zeljko.fili...@gmail.comwrote:

 On Mon, Mar 18, 2013 at 2:40 PM, Sohail Mirza mrz...@gmail.com wrote:

 input id=btnAddNewCustomer type=submit class=ui-button Action
 value=Create New Customer onclick=createNewCustomer()


 Can you post a link to the page where the problem is reproducible?

 Željko

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] Watir-Webdriver Save Image

2013-03-17 Thread Sohail Mirza
Hi,

I am trying to find the way to save an image when something fail but could
not get much stuff from google.
I am using Watir-WebDriver and needs to save an image in case failure.

Could anyone advise how to save image?
Thanks

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] Re: Watir-Webdriver Save Image

2013-03-17 Thread Sohail Mirza
i means how to save screenshot

On Sun, Mar 17, 2013 at 12:29 PM, Sohail Mirza mrz...@gmail.com wrote:

 Hi,

 I am trying to find the way to save an* screenshot* when something fail
 but could not get much stuff from google.
 I am using Watir-WebDriver and needs to save an image in case failure.

 Could anyone advise how to save image?
 Thanks


-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Watir HTML Reports

2013-03-14 Thread Sohail Mirza
so it is concluded that Cucumber framework has better HTML reporting
techniques.
Could you comments some good cucumber articles? i searched myself but
hardly find anything good.


On Wed, Mar 13, 2013 at 9:00 PM, Chuck van der Linden 
cvanderlin...@climate.com wrote:

 On Wednesday, March 13, 2013 4:56:52 AM UTC-7, Željko Filipin wrote:

 On Wed, Mar 13, 2013 at 8:28 AM, Sohail Mirza mrz...@gmail.com wrote:

 i need to create HTML reports in Watir.


 Watir just drives browsers, it does not create reports. I think that
 all testing frameworks (test/unit, rspec, cucumber) have reporting. I use
 cucumber and it has really nice HTML report.

 Željko
 --
 https://leanpub.com/watirbook


 I'll second this, there are also a number of other great reasons to use
 cucumber  (see the first two chapters of the book Specification by Example,
 free at this link  http://www.manning.com/adzic/

 The example you noted above is just using ordinary ruby scripting commands
 to create an html report as the script runs.  which is fine if you want
 everything in one long script (bad Idea really) but harder to implement if
 you want to be able to run individual scripts, sections, or a whole suite
 as your needs require.

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] on error continue execution

2013-03-14 Thread Sohail Mirza
Hi

I am trying to find out the way that *how to continue test cases execution
on error*. Right now test case execution stops as soon some error encounter
during test execution.
I am using Watir Test/Unit framework.

Any comments please?

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] Watir HTML Reports

2013-03-13 Thread Sohail Mirza
Hi,

i need to create HTML reports in Watir.
There is one HTML Report Class which i found in google results. i wanted to
confirm is that still the only way to generate HTML reports or there are
some more good approaches to generate HTML Reports?
http://wiki.openqa.org/display/WTR/HTML+report+class



Thanks for the comments.

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] bluetooth_adapter_win.cc(23)] NOT IMPLEMENTED

2013-02-18 Thread Sohail Mirza
Hi,

I would like to know the specific reason for the following error which
comes when i execute the Watir Script *(Though script executed perfectly
and gives the required output)*

*[10152:11076:0218/180847:ERROR:master_preferences.cc(104)] Failed to read
master*
*_preferences file at C:\Program
Files\Google\Chrome\Application\master_preferenc*
*es. Falling back to default preferences.*
*[10152:11076:0218/180848:ERROR:bluetooth_adapter_win.cc(23)] NOT
IMPLEMENTED*
*
*
*
*
Regards,
Sohail

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] watir-webdriver href javascript

2013-02-06 Thread Sohail Mirza
Hi,

how would you automate following Javascript link in watir-webdriver?

a
href='javascript:selectDevice(122334455,12121212,#divAddCustomerLine);'Select/a


Thanks

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Re: watir-webdriver href javascript

2013-02-06 Thread Sohail Mirza
Thanks Alex, its working with me.


On Wed, Feb 6, 2013 at 1:18 PM, Alex Shtayer ashta...@gmail.com wrote:

 What do you mean by automate? How to click on the element?

 You can use usual method like:
 browser.link(:text, Select).click
 or if due any reason click method does not work:
 browser.link(:text, Select).fire_event(onclick)
 or
 browser.link(:text, Select).fire_event(onmousedown)


 On Wednesday, February 6, 2013 11:11:52 AM UTC+2, mc060200778 wrote:

 Hi,

 how would you automate following Javascript link in watir-webdriver?

 a href='javascript:selectDevice(**122334455,12121212,#**
 divAddCustomerLine);'Select**/a


 Thanks

  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] input type=image

2013-02-04 Thread Sohail Mirza
Hi,

i have following html code for input type *image*

*input type=image src=/MyTestDemo/Images/add.png value=Add New
Customer data-bind=visible: IsAddAllowed,click: $root.AddNewCustomer
class=ui-button*

How can i perform click event on above?
i am trying the following but failing

*@browser.button(:src,/MyTestDemo/Images/add/).click*
*@browser.button(:class = ui-button).click*

Please

Thanks

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] .attach method

2013-02-02 Thread Sohail Mirza
Hi,

I just found that Watir has the *.attach* method. The examples use IE
browser.
How do I attach to an existing browser window using *watir-webdriver*?


Thanks.
Sohail

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] .attach method

2013-02-02 Thread Sohail Mirza
Thanks Jim, helps a lot.

Regards,
Sohail

On Sat, Feb 2, 2013 at 8:45 PM, Jim Evans james.h.evans...@gmail.comwrote:

 You don't. The WebDriver API doesn't support attaching to an existing
 browser yet, so watir-webdriver can't provide this functionality either.
 Additionally, a large use case for attaching to an existing browser window
 is in manipulating popup browser windows[1], and WebDriver does provide a
 Window API for that purpose. How watir-webdriver exploits that API, I
 couldn't say.

 --Jim

 [1] Disclaimer: I don't mean to suggest that there aren't other use cases
 for the .attach method, or that popup windows are the most important use
 case for that API, or even that it's the use case you're trying to solve.
 I'm just presenting the state of things as they are in WebDriver. Patches,
 as always, gratefully received.

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] Chrome automation using watir

2013-02-01 Thread Sohail Mirza
Hi,

I wanted to know that is it possible to automate Chrome using watir? i did
some google on using watir with chrome but could not find much.
Where can i find some good information about the subject?



Thanks,
Sohail

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] Test::Unit::TestCase

2013-02-01 Thread Sohail Mirza
Hi,

Can i use *Test::Unit::TestCase *framework with Watir-Webdriver? if not
then can some recommend useful framework to automate Asp.net MVC
application + jquery?


Thanks,
Sohail

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] How to run watir script onan already opened Chrome Browser

2013-02-01 Thread Sohail Mirza
Hi,

I wanted to know How to run watir script on an already opened Chrome
Browser.
I dont want to open new Chrome Instance. THe web application is already
openened in Chrome and i just want to run the script.

Thanks for comments

Sohail

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Test::Unit::TestCase

2013-02-01 Thread Sohail Mirza
John, Thanks,

then what is equivalent to *Test::Unit::TestCase* watir-webdriver?
What are the available frameworks in watir-webdriver?

Is Test::Unit::TestCase is still available and being used?

Thanks for your comments.
Sohail

On Fri, Feb 1, 2013 at 8:31 PM, John Fitisoff jfitis...@yahoo.com wrote:

 Sure. They are two different things that don't interact directly with each
 other.

   --
 *From:* Sohail Mirza mrz...@gmail.com
 *To:* watir-general@googlegroups.com
 *Sent:* Friday, February 1, 2013 8:12 AM
 *Subject:* [wtr-general] Test::Unit::TestCase

 Hi,

 Can i use *Test::Unit::TestCase *framework with Watir-Webdriver? if not
 then can some recommend useful framework to automate 
 Asp.nethttp://asp.net/MVC application + jquery?


 Thanks,
 Sohail





 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




   --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] query

2013-01-30 Thread Sohail Mirza
How do i check version of my installed watir?



Thanks

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] query

2013-01-30 Thread Sohail Mirza
Thanks Joe,
it helped.

On Wed, Jan 30, 2013 at 10:00 PM, Joe Fleck joeflec...@gmail.com wrote:

 Command line
 Ruby - v
 Or
 Gem list

 All lower case
 On Jan 30, 2013 12:56 PM, Sohail Mirza mrz...@gmail.com wrote:

 How do i check version of my installed watir?



 Thanks

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.



  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] How to automate Sub Menu using Wtir?

2013-01-30 Thread Sohail Mirza
Hi folks,

I need to select sub menu item. How can i automate this? I am using
Watir-Classic gem.

The view source shows following

li
a href=/MyDemoTest/Menu/LoadView?*menuItemKey=1*
onclick=ShowLoadingIndicator();Test Management/a
/li


Thanks,

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] How to automate Sub Menu using Wtir?

2013-01-30 Thread Sohail Mirza
okay, i do that and reverts back. Meanwhile i have another question which i
ask in separate email thread.
Thanks




On Wed, Jan 30, 2013 at 10:58 PM, Joe Fleck joeflec...@gmail.com wrote:

 Hi,

 First thing.. make sure you use firebug or developer tool to get the
 html.  Don't use view source.

 You will need to first expose the submenu and then select the submenu item
 you want.

 Repost the html code here and we will be better able to help you.

 Joe
 On Jan 30, 2013 1:55 PM, Sohail Mirza mrz...@gmail.com wrote:

 Hi folks,

 I need to select sub menu item. How can i automate this? I am using
 Watir-Classic gem.

 The view source shows following

 li
 a href=/MyDemoTest/Menu/LoadView?*menuItemKey=1*
 onclick=ShowLoadingIndicator();Test Management/a
 /li


 Thanks,

  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.



  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] Watir Classic versus Watir-WebDriver?

2013-01-30 Thread Sohail Mirza
Hi,

I need to test my web application in Google Chrome. My web application is
developed using MVC + Jquery technology.
Can i use Watir-Classic to automate my application in Chrome or i need to
use Watir-webdriver?


Thanks.

-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] How to automate Sub Menu using Wtir?

2013-01-30 Thread Sohail Mirza
Joe,

Are you asking for this?
i used Chrome Develope Tool and found the following.


li class=potato-menu-item potato-menu-has-vertical
Main1
ul class=subMenu potato-menu-group potato-menu-vertical
style=left: 0px; display: none;

li class=potato-menu-item

a href=/MyDemoTest/Menu/LoadView?menuItemKey=1
onclick=ShowLoadingIndicator();Sub Menu 1/a

/li
li class=potato-menu-item

a href=/MyDemoTest/Menu/LoadView?menuItemKey=6
onclick=ShowLoadingIndicator();Sub Menu 2/a

/li
li class=potato-menu-item

a href=/MyDemoTest/Menu/LoadView?menuItemKey=7
onclick=ShowLoadingIndicator();Sub Menu 3/a

/li

/ul

/li




On Wed, Jan 30, 2013 at 10:58 PM, Joe Fleck joeflec...@gmail.com wrote:

 Hi,

 First thing.. make sure you use firebug or developer tool to get the
 html.  Don't use view source.

 You will need to first expose the submenu and then select the submenu item
 you want.

 Repost the html code here and we will be better able to help you.

 Joe
 On Jan 30, 2013 1:55 PM, Sohail Mirza mrz...@gmail.com wrote:

 Hi folks,

 I need to select sub menu item. How can i automate this? I am using
 Watir-Classic gem.

 The view source shows following

 li
 a href=/MyDemoTest/Menu/LoadView?*menuItemKey=1*
 onclick=ShowLoadingIndicator();Test Management/a
 /li


 Thanks,

  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.



  --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] How to automate Sub Menu using Wtir?

2013-01-30 Thread Sohail Mirza
Joe,

i tried following

@browser.li(:class=potato-menu-item potato-menu-has-vertical).click
@browser.a(:text='Sub Menu 1').click

D:/Watir/Examples/Test1.rb:4:in `main': undefined method `li' for
nil:NilClass
 (NoMethodError)



On Wed, Jan 30, 2013 at 11:43 PM, Joe Fleck joeflec...@gmail.com wrote:

 Hi Sohail,

 Yes.

 @browser.li(:class=potato-menu-item potato-menu-has-vertical).click
 @browser.a(:text='Sub Menu 1').click


 Sometimes it is difficult to run these steps in irb.  I would suggest
 creating a method then calling it in irb.

 do first

 def click_sub_menu()
 @browser.li(:class=potato-menu-item potato-menu-has-vertical).click
 @browser.a(:text='Sub Menu 1').click
 end

 then call it
 click_sub_menu


 Hope this helps.

 Joe


 On Wed, Jan 30, 2013 at 2:35 PM, Sohail Mirza mrz...@gmail.com wrote:
  Joe,
 
  Are you asking for this?
  i used Chrome Develope Tool and found the following.
 
 
  li class=potato-menu-item potato-menu-has-vertical
  Main1
  ul class=subMenu potato-menu-group potato-menu-vertical
  style=left: 0px; display: none;
 
  li class=potato-menu-item
 
  a href=/MyDemoTest/Menu/LoadView?menuItemKey=1
  onclick=ShowLoadingIndicator();Sub Menu 1/a
 
  /li
  li class=potato-menu-item
 
  a href=/MyDemoTest/Menu/LoadView?menuItemKey=6
  onclick=ShowLoadingIndicator();Sub Menu 2/a
 
  /li
  li class=potato-menu-item
 
  a href=/MyDemoTest/Menu/LoadView?menuItemKey=7
  onclick=ShowLoadingIndicator();Sub Menu 3/a
 
  /li
 
  /ul
 
  /li
 
 
 
 
  On Wed, Jan 30, 2013 at 10:58 PM, Joe Fleck joeflec...@gmail.com
 wrote:
 
  Hi,
 
  First thing.. make sure you use firebug or developer tool to get the
 html.
  Don't use view source.
 
  You will need to first expose the submenu and then select the submenu
 item
  you want.
 
  Repost the html code here and we will be better able to help you.
 
  Joe
 
  On Jan 30, 2013 1:55 PM, Sohail Mirza mrz...@gmail.com wrote:
 
  Hi folks,
 
  I need to select sub menu item. How can i automate this? I am using
  Watir-Classic gem.
 
  The view source shows following
 
  li
  a href=/MyDemoTest/Menu/LoadView?menuItemKey=1
  onclick=ShowLoadingIndicator();Test Management/a
  /li
 
 
  Thanks,
 
  --
  --
  Before posting, please read http://watir.com/support. In short: search
  before you ask, be nice.
 
  watir-general@googlegroups.com
  http://groups.google.com/group/watir-general
  watir-general+unsubscr...@googlegroups.com
 
  ---
  You received this message because you are subscribed to the Google
 Groups
  Watir General group.
  To unsubscribe from this group and stop receiving emails from it, send
 an
  email to watir-general+unsubscr...@googlegroups.com.
  For more options, visit https://groups.google.com/groups/opt_out.
 
 
 
  --
  --
  Before posting, please read http://watir.com/support. In short: search
  before you ask, be nice.
 
  watir-general@googlegroups.com
  http://groups.google.com/group/watir-general
  watir-general+unsubscr...@googlegroups.com
 
  ---
  You received this message because you are subscribed to the Google
 Groups
  Watir General group.
  To unsubscribe from this group and stop receiving emails from it, send
 an
  email to watir-general+unsubscr...@googlegroups.com.
  For more options, visit https://groups.google.com/groups/opt_out.
 
 
 
 
  --
  --
  Before posting, please read http://watir.com/support. In short: search
  before you ask, be nice.
 
  watir-general@googlegroups.com
  http://groups.google.com/group/watir-general
  watir-general+unsubscr...@googlegroups.com
 
  ---
  You received this message because you are subscribed to the Google Groups
  Watir General group.
  To unsubscribe from this group and stop receiving emails from it, send an
  email to watir-general+unsubscr...@googlegroups.com.
  For more options, visit https://groups.google.com/groups/opt_out.
 
 

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] How to automate Sub Menu using Wtir?

2013-01-30 Thread Sohail Mirza
Yes Joe, you are right. i changed @browser to what i initialized and now
the following line is working.
browser.li(:class=potato-menu-item potato-menu-has-vertical).click


However,  i am getting another error for second line

*browser.a(:text='Sub Menu 1').click*
*
*
C:/Ruby193/lib/ruby/gems/1.9.1/gems/watir-webdriver-0.6.2/lib/watir-webdriver/el
ements/element.rb:490:in `assert_exists': unable to locate element, using
{:text
=Sub Menu 1, :tag_name=a} (Watir::Exception::UnknownObjectException)
from
C:/Ruby193/lib/ruby/gems/1.9.1/gems/watir-webdriver-0.6.2/lib/watir
-webdriver/elements/element.rb:118:in `click'
from D:/Watir/Examples/Test1.rb:5:in `main'



On Wed, Jan 30, 2013 at 11:51 PM, Joe Fleck joeflec...@gmail.com wrote:

 Okay.

 you need to change my @browser to what you initialized your browser as.

 Joe

 # if you have to sign in do that


 On Wed, Jan 30, 2013 at 2:48 PM, Sohail Mirza mrz...@gmail.com wrote:
  Joe,
 
  i tried following
 
  @browser.li(:class=potato-menu-item potato-menu-has-vertical).click
  @browser.a(:text='Sub Menu 1').click
 
  D:/Watir/Examples/Test1.rb:4:in `main': undefined method `li' for
  nil:NilClass
   (NoMethodError)
 
 
 
  On Wed, Jan 30, 2013 at 11:43 PM, Joe Fleck joeflec...@gmail.com
 wrote:
 
  Hi Sohail,
 
  Yes.
 
  @browser.li(:class=potato-menu-item potato-menu-has-vertical).click
  @browser.a(:text='Sub Menu 1').click
 
 
  Sometimes it is difficult to run these steps in irb.  I would suggest
  creating a method then calling it in irb.
 
  do first
 
  def click_sub_menu()
  @browser.li(:class=potato-menu-item
 potato-menu-has-vertical).click
  @browser.a(:text='Sub Menu 1').click
  end
 
  then call it
  click_sub_menu
 
 
  Hope this helps.
 
  Joe
 
 
  On Wed, Jan 30, 2013 at 2:35 PM, Sohail Mirza mrz...@gmail.com wrote:
   Joe,
  
   Are you asking for this?
   i used Chrome Develope Tool and found the following.
  
  
   li class=potato-menu-item potato-menu-has-vertical
   Main1
   ul class=subMenu potato-menu-group potato-menu-vertical
   style=left: 0px; display: none;
  
   li class=potato-menu-item
  
   a href=/MyDemoTest/Menu/LoadView?menuItemKey=1
   onclick=ShowLoadingIndicator();Sub Menu 1/a
  
   /li
   li class=potato-menu-item
  
   a href=/MyDemoTest/Menu/LoadView?menuItemKey=6
   onclick=ShowLoadingIndicator();Sub Menu 2/a
  
   /li
   li class=potato-menu-item
  
   a href=/MyDemoTest/Menu/LoadView?menuItemKey=7
   onclick=ShowLoadingIndicator();Sub Menu 3/a
  
   /li
  
   /ul
  
   /li
  
  
  
  
   On Wed, Jan 30, 2013 at 10:58 PM, Joe Fleck joeflec...@gmail.com
   wrote:
  
   Hi,
  
   First thing.. make sure you use firebug or developer tool to get the
   html.
   Don't use view source.
  
   You will need to first expose the submenu and then select the submenu
   item
   you want.
  
   Repost the html code here and we will be better able to help you.
  
   Joe
  
   On Jan 30, 2013 1:55 PM, Sohail Mirza mrz...@gmail.com wrote:
  
   Hi folks,
  
   I need to select sub menu item. How can i automate this? I am using
   Watir-Classic gem.
  
   The view source shows following
  
   li
   a href=/MyDemoTest/Menu/LoadView?menuItemKey=1
   onclick=ShowLoadingIndicator();Test Management/a
   /li
  
  
   Thanks,
  
   --
   --
   Before posting, please read http://watir.com/support. In short:
 search
   before you ask, be nice.
  
   watir-general@googlegroups.com
   http://groups.google.com/group/watir-general
   watir-general+unsubscr...@googlegroups.com
  
   ---
   You received this message because you are subscribed to the Google
   Groups
   Watir General group.
   To unsubscribe from this group and stop receiving emails from it,
 send
   an
   email to watir-general+unsubscr...@googlegroups.com.
   For more options, visit https://groups.google.com/groups/opt_out.
  
  
  
   --
   --
   Before posting, please read http://watir.com/support. In short:
 search
   before you ask, be nice.
  
   watir-general@googlegroups.com
   http://groups.google.com/group/watir-general
   watir-general+unsubscr...@googlegroups.com
  
   ---
   You received this message because you are subscribed to the Google
   Groups
   Watir General group.
   To unsubscribe from this group and stop receiving emails from it,
 send
   an
   email to watir-general+unsubscr...@googlegroups.com.
   For more options, visit https://groups.google.com/groups/opt_out.
  
  
  
  
   --
   --
   Before posting, please read http://watir.com/support. In short:
 search
   before you ask, be nice.
  
   watir-general@googlegroups.com
   http://groups.google.com/group/watir-general
   watir-general+unsubscr...@googlegroups.com
  
   ---
   You received this message because you are subscribed to the Google
   Groups
   Watir General group.
   To unsubscribe from this group and stop receiving emails from it, send
   an
   email to watir-general+unsubscr...@googlegroups.com.
   For more options

Re: [wtr-general] How to automate Sub Menu using Wtir?

2013-01-30 Thread Sohail Mirza
Sorry my mistake here.

Sub Menu 1 was a dummy name. i replaced it with real name and now it is
working fine. Great
*Thanks a lot Joe for your kind help. Much appreciated.*




On Wed, Jan 30, 2013 at 11:51 PM, Joe Fleck joeflec...@gmail.com wrote:

 Okay.

 you need to change my @browser to what you initialized your browser as.

 Joe

 # if you have to sign in do that


 On Wed, Jan 30, 2013 at 2:48 PM, Sohail Mirza mrz...@gmail.com wrote:
  Joe,
 
  i tried following
 
  @browser.li(:class=potato-menu-item potato-menu-has-vertical).click
  @browser.a(:text='Sub Menu 1').click
 
  D:/Watir/Examples/Test1.rb:4:in `main': undefined method `li' for
  nil:NilClass
   (NoMethodError)
 
 
 
  On Wed, Jan 30, 2013 at 11:43 PM, Joe Fleck joeflec...@gmail.com
 wrote:
 
  Hi Sohail,
 
  Yes.
 
  @browser.li(:class=potato-menu-item potato-menu-has-vertical).click
  @browser.a(:text='Sub Menu 1').click
 
 
  Sometimes it is difficult to run these steps in irb.  I would suggest
  creating a method then calling it in irb.
 
  do first
 
  def click_sub_menu()
  @browser.li(:class=potato-menu-item
 potato-menu-has-vertical).click
  @browser.a(:text='Sub Menu 1').click
  end
 
  then call it
  click_sub_menu
 
 
  Hope this helps.
 
  Joe
 
 
  On Wed, Jan 30, 2013 at 2:35 PM, Sohail Mirza mrz...@gmail.com wrote:
   Joe,
  
   Are you asking for this?
   i used Chrome Develope Tool and found the following.
  
  
   li class=potato-menu-item potato-menu-has-vertical
   Main1
   ul class=subMenu potato-menu-group potato-menu-vertical
   style=left: 0px; display: none;
  
   li class=potato-menu-item
  
   a href=/MyDemoTest/Menu/LoadView?menuItemKey=1
   onclick=ShowLoadingIndicator();Sub Menu 1/a
  
   /li
   li class=potato-menu-item
  
   a href=/MyDemoTest/Menu/LoadView?menuItemKey=6
   onclick=ShowLoadingIndicator();Sub Menu 2/a
  
   /li
   li class=potato-menu-item
  
   a href=/MyDemoTest/Menu/LoadView?menuItemKey=7
   onclick=ShowLoadingIndicator();Sub Menu 3/a
  
   /li
  
   /ul
  
   /li
  
  
  
  
   On Wed, Jan 30, 2013 at 10:58 PM, Joe Fleck joeflec...@gmail.com
   wrote:
  
   Hi,
  
   First thing.. make sure you use firebug or developer tool to get the
   html.
   Don't use view source.
  
   You will need to first expose the submenu and then select the submenu
   item
   you want.
  
   Repost the html code here and we will be better able to help you.
  
   Joe
  
   On Jan 30, 2013 1:55 PM, Sohail Mirza mrz...@gmail.com wrote:
  
   Hi folks,
  
   I need to select sub menu item. How can i automate this? I am using
   Watir-Classic gem.
  
   The view source shows following
  
   li
   a href=/MyDemoTest/Menu/LoadView?menuItemKey=1
   onclick=ShowLoadingIndicator();Test Management/a
   /li
  
  
   Thanks,
  
   --
   --
   Before posting, please read http://watir.com/support. In short:
 search
   before you ask, be nice.
  
   watir-general@googlegroups.com
   http://groups.google.com/group/watir-general
   watir-general+unsubscr...@googlegroups.com
  
   ---
   You received this message because you are subscribed to the Google
   Groups
   Watir General group.
   To unsubscribe from this group and stop receiving emails from it,
 send
   an
   email to watir-general+unsubscr...@googlegroups.com.
   For more options, visit https://groups.google.com/groups/opt_out.
  
  
  
   --
   --
   Before posting, please read http://watir.com/support. In short:
 search
   before you ask, be nice.
  
   watir-general@googlegroups.com
   http://groups.google.com/group/watir-general
   watir-general+unsubscr...@googlegroups.com
  
   ---
   You received this message because you are subscribed to the Google
   Groups
   Watir General group.
   To unsubscribe from this group and stop receiving emails from it,
 send
   an
   email to watir-general+unsubscr...@googlegroups.com.
   For more options, visit https://groups.google.com/groups/opt_out.
  
  
  
  
   --
   --
   Before posting, please read http://watir.com/support. In short:
 search
   before you ask, be nice.
  
   watir-general@googlegroups.com
   http://groups.google.com/group/watir-general
   watir-general+unsubscr...@googlegroups.com
  
   ---
   You received this message because you are subscribed to the Google
   Groups
   Watir General group.
   To unsubscribe from this group and stop receiving emails from it, send
   an
   email to watir-general+unsubscr...@googlegroups.com.
   For more options, visit https://groups.google.com/groups/opt_out.
  
  
 
  --
  --
  Before posting, please read http://watir.com/support. In short: search
  before you ask, be nice.
 
  watir-general@googlegroups.com
  http://groups.google.com/group/watir-general
  watir-general+unsubscr...@googlegroups.com
 
  ---
  You received this message because you are subscribed to the Google
 Groups
  Watir General group.
  To unsubscribe from this group and stop receiving emails from it, send
 an
  email to watir-general

Re: [wtr-general] How to automate Sub Menu using Wtir?

2013-01-30 Thread Sohail Mirza
Joe,

Currently my script is working with FireFox as i am using watir-webdriver.

Lets say if i want to make the same script compatible with Google Chrome
what pre-requisists i should i follow?
Do i need to install ChromDriver? if yes how to download and configure it?
what should i put in require  in my script?

Do you have simple example for developing script for chrome??
Thanks


On Thu, Jan 31, 2013 at 12:05 AM, Joe Fleck joeflec...@gmail.com wrote:

 No problem.

 On Wed, Jan 30, 2013 at 3:04 PM, Sohail Mirza mrz...@gmail.com wrote:
  Sorry my mistake here.
 
  Sub Menu 1 was a dummy name. i replaced it with real name and now it is
  working fine. Great
  Thanks a lot Joe for your kind help. Much appreciated.
 
 
 
 
  On Wed, Jan 30, 2013 at 11:51 PM, Joe Fleck joeflec...@gmail.com
 wrote:
 
  Okay.
 
  you need to change my @browser to what you initialized your browser as.
 
  Joe
 
  # if you have to sign in do that
 
 
  On Wed, Jan 30, 2013 at 2:48 PM, Sohail Mirza mrz...@gmail.com wrote:
   Joe,
  
   i tried following
  
   @browser.li(:class=potato-menu-item
 potato-menu-has-vertical).click
   @browser.a(:text='Sub Menu 1').click
  
   D:/Watir/Examples/Test1.rb:4:in `main': undefined method `li' for
   nil:NilClass
(NoMethodError)
  
  
  
   On Wed, Jan 30, 2013 at 11:43 PM, Joe Fleck joeflec...@gmail.com
   wrote:
  
   Hi Sohail,
  
   Yes.
  
   @browser.li(:class=potato-menu-item
 potato-menu-has-vertical).click
   @browser.a(:text='Sub Menu 1').click
  
  
   Sometimes it is difficult to run these steps in irb.  I would suggest
   creating a method then calling it in irb.
  
   do first
  
   def click_sub_menu()
   @browser.li(:class=potato-menu-item
   potato-menu-has-vertical).click
   @browser.a(:text='Sub Menu 1').click
   end
  
   then call it
   click_sub_menu
  
  
   Hope this helps.
  
   Joe
  
  
   On Wed, Jan 30, 2013 at 2:35 PM, Sohail Mirza mrz...@gmail.com
 wrote:
Joe,
   
Are you asking for this?
i used Chrome Develope Tool and found the following.
   
   
li class=potato-menu-item potato-menu-has-vertical
Main1
ul class=subMenu potato-menu-group
potato-menu-vertical
style=left: 0px; display: none;
   
li class=potato-menu-item
   
a href=/MyDemoTest/Menu/LoadView?menuItemKey=1
onclick=ShowLoadingIndicator();Sub Menu 1/a
   
/li
li class=potato-menu-item
   
a href=/MyDemoTest/Menu/LoadView?menuItemKey=6
onclick=ShowLoadingIndicator();Sub Menu 2/a
   
/li
li class=potato-menu-item
   
a href=/MyDemoTest/Menu/LoadView?menuItemKey=7
onclick=ShowLoadingIndicator();Sub Menu 3/a
   
/li
   
/ul
   
/li
   
   
   
   
On Wed, Jan 30, 2013 at 10:58 PM, Joe Fleck joeflec...@gmail.com
wrote:
   
Hi,
   
First thing.. make sure you use firebug or developer tool to get
 the
html.
Don't use view source.
   
You will need to first expose the submenu and then select the
submenu
item
you want.
   
Repost the html code here and we will be better able to help you.
   
Joe
   
On Jan 30, 2013 1:55 PM, Sohail Mirza mrz...@gmail.com wrote:
   
Hi folks,
   
I need to select sub menu item. How can i automate this? I am
 using
Watir-Classic gem.
   
The view source shows following
   
li
a href=/MyDemoTest/Menu/LoadView?menuItemKey=1
onclick=ShowLoadingIndicator();Test Management/a
/li
   
   
Thanks,
   
--
--
Before posting, please read http://watir.com/support. In short:
search
before you ask, be nice.
   
watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com
   
---
You received this message because you are subscribed to the
 Google
Groups
Watir General group.
To unsubscribe from this group and stop receiving emails from it,
send
an
email to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out
 .
   
   
   
--
--
Before posting, please read http://watir.com/support. In short:
search
before you ask, be nice.
   
watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com
   
---
You received this message because you are subscribed to the Google
Groups
Watir General group.
To unsubscribe from this group and stop receiving emails from it,
send
an
email to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
   
   
   
   
--
--
Before posting, please read http://watir.com/support. In short:
search
before you ask, be nice.
   
watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

Re: [wtr-general] How to automate Sub Menu using Wtir?

2013-01-30 Thread Sohail Mirza
Well the issue mentioned below has been resolved.
I just copied the chromedriver binary file at the location defined in my
Path environment variable

Thanks

On Thu, Jan 31, 2013 at 12:42 AM, Sohail Mirza mrz...@gmail.com wrote:

 Joe,
 i downloaded chromedriver file and extracted it.

 When i run my script, i am getting following issue :( *Do you have an
 idea where i should exactly place the chromedriver binary file?*


 D:\Watir\ExamplesTest1.rb

 C:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2/lib/selenium/webdr
 iver/chrome/service.rb:20:in `executable_path': Unable to find the
 chromedriver
 executable. Please download the server from
 http://code.google.com/p/chromedrive
 r/downloads/list and place it somewhere on your PATH. More info at
 http://code.g
 oogle.com/p/selenium/wiki/ChromeDriver.
 (Selenium::WebDriver::Error::WebDriverEr
 ror)


 On Thu, Jan 31, 2013 at 12:23 AM, Joe Fleck joeflec...@gmail.com wrote:

 Yes you will need to install the chromeDriver.  If you download this book:
 Homebrewer's Guide to Watir
 it will walk through all the necessary steps.  You can find it here 
 https://leanpub.com/watirbook 

 joe

 On Wed, Jan 30, 2013 at 3:17 PM, Sohail Mirza mrz...@gmail.com wrote:
  Joe,
 
  Currently my script is working with FireFox as i am using
 watir-webdriver.
 
  Lets say if i want to make the same script compatible with Google Chrome
  what pre-requisists i should i follow?
  Do i need to install ChromDriver? if yes how to download and configure
 it?
  what should i put in require  in my script?
 
  Do you have simple example for developing script for chrome??
  Thanks
 
 
  On Thu, Jan 31, 2013 at 12:05 AM, Joe Fleck joeflec...@gmail.com
 wrote:
 
  No problem.
 
  On Wed, Jan 30, 2013 at 3:04 PM, Sohail Mirza mrz...@gmail.com
 wrote:
   Sorry my mistake here.
  
   Sub Menu 1 was a dummy name. i replaced it with real name and now it
 is
   working fine. Great
   Thanks a lot Joe for your kind help. Much appreciated.
  
  
  
  
   On Wed, Jan 30, 2013 at 11:51 PM, Joe Fleck joeflec...@gmail.com
   wrote:
  
   Okay.
  
   you need to change my @browser to what you initialized your browser
 as.
  
   Joe
  
   # if you have to sign in do that
  
  
   On Wed, Jan 30, 2013 at 2:48 PM, Sohail Mirza mrz...@gmail.com
 wrote:
Joe,
   
i tried following
   
@browser.li(:class=potato-menu-item
potato-menu-has-vertical).click
@browser.a(:text='Sub Menu 1').click
   
D:/Watir/Examples/Test1.rb:4:in `main': undefined method `li'
 for
nil:NilClass
 (NoMethodError)
   
   
   
On Wed, Jan 30, 2013 at 11:43 PM, Joe Fleck joeflec...@gmail.com
 
wrote:
   
Hi Sohail,
   
Yes.
   
@browser.li(:class=potato-menu-item
potato-menu-has-vertical).click
@browser.a(:text='Sub Menu 1').click
   
   
Sometimes it is difficult to run these steps in irb.  I would
suggest
creating a method then calling it in irb.
   
do first
   
def click_sub_menu()
@browser.li(:class=potato-menu-item
potato-menu-has-vertical).click
@browser.a(:text='Sub Menu 1').click
end
   
then call it
click_sub_menu
   
   
Hope this helps.
   
Joe
   
   
On Wed, Jan 30, 2013 at 2:35 PM, Sohail Mirza mrz...@gmail.com
wrote:
 Joe,

 Are you asking for this?
 i used Chrome Develope Tool and found the following.


 li class=potato-menu-item potato-menu-has-vertical
 Main1
 ul class=subMenu potato-menu-group
 potato-menu-vertical
 style=left: 0px; display: none;

 li class=potato-menu-item

 a href=/MyDemoTest/Menu/LoadView?menuItemKey=1
 onclick=ShowLoadingIndicator();Sub Menu 1/a

 /li
 li class=potato-menu-item

 a href=/MyDemoTest/Menu/LoadView?menuItemKey=6
 onclick=ShowLoadingIndicator();Sub Menu 2/a

 /li
 li class=potato-menu-item

 a href=/MyDemoTest/Menu/LoadView?menuItemKey=7
 onclick=ShowLoadingIndicator();Sub Menu 3/a

 /li

 /ul

 /li




 On Wed, Jan 30, 2013 at 10:58 PM, Joe Fleck 
 joeflec...@gmail.com
 wrote:

 Hi,

 First thing.. make sure you use firebug or developer tool to
 get
 the
 html.
 Don't use view source.

 You will need to first expose the submenu and then select the
 submenu
 item
 you want.

 Repost the html code here and we will be better able to help
 you.

 Joe

 On Jan 30, 2013 1:55 PM, Sohail Mirza mrz...@gmail.com
 wrote:

 Hi folks,

 I need to select sub menu item. How can i automate this? I am
 using
 Watir-Classic gem.

 The view source shows following

 li
 a href=/MyDemoTest/Menu/LoadView?menuItemKey=1
 onclick=ShowLoadingIndicator();Test Management/a
 /li


 Thanks,

 --
 --
 Before posting

Re: [wtr-general] Watir Classic versus Watir-WebDriver?

2013-01-30 Thread Sohail Mirza
Hi, Thanks for your reply.

I have following simple example to automate a scenario in Chrome but i am
getting following error when i execute it. (FYI: The following Test1.rb
works fine in FF browser)

*Test1.rb*
require 'watir-webdriver'
browser = Watir::Browser.new :chrome
browser.goto (http://localhost/MyDemoTEST;)
browser.li(:class=potato-menu-item potato-menu-has-vertical).click
browser.a(:text='My Management').click



*D:\Watir\ExamplesTest1.rb*
Started ChromeDriver
port=9515
version=26.0.1383.0
log=D:\Watir\Examples\chromedriver.log
[8112:8700:0131/011355:ERROR:master_preferences.cc(104)] Failed to read
master_p
references file at C:\Program
Files\Google\Chrome\Application\master_preferences
. Falling back to default preferences.
[8112:8700:0131/011355:ERROR:bluetooth_adapter_win.cc(23)] NOT IMPLEMENTED
C:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2/lib/selenium/webdr
iver/remote/response.rb:52:in `assert_ok': Navigation failed with error
code=2.
(Selenium::WebDriver::Error::UnknownError)
from
C:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2/lib/s
elenium/webdriver/remote/response.rb:15:in `initialize'
from
C:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2/lib/s
elenium/webdriver/remote/http/common.rb:59:in `new'
from
C:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2/lib/s
elenium/webdriver/remote/http/common.rb:59:in `create_response'
from
C:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2/lib/s
elenium/webdriver/remote/http/default.rb:66:in `request'
from
C:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2/lib/s
elenium/webdriver/remote/http/common.rb:40:in `call'
from
C:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2/lib/s
elenium/webdriver/remote/bridge.rb:615:in `raw_execute'
from
C:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2/lib/s
elenium/webdriver/remote/bridge.rb:593:in `execute'
from
C:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2/lib/s
elenium/webdriver/remote/bridge.rb:99:in `get'
from
C:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2/lib/s
elenium/webdriver/common/navigation.rb:14:in `to'
from
C:/Ruby193/lib/ruby/gems/1.9.1/gems/watir-webdriver-0.6.2/lib/watir
-webdriver/browser.rb:77:in `goto'
from D:/Watir/Examples/Test1.rb:3:in `main'

D:\Watir\Examples[WARNING:..\..\..\..\flash\platform\pepper\pep_module.cpp(63)]
 SANDBOXED


On Thu, Jan 31, 2013 at 1:13 AM, Željko Filipin zeljko.fili...@gmail.comwrote:

 On Wed, Jan 30, 2013 at 8:14 PM, Sohail Mirza mrz...@gmail.com wrote:

 Can i use Watir-Classic to automate my application in Chrome or i need to
 use Watir-webdriver?


 watir-classic gem can only automate Internet Explorer. If you want to
 automate Crome, you have to use watir-webdriver gem.

 Željko
 --
 https://leanpub.com/watirbook

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [wtr-general] Watir Classic versus Watir-WebDriver?

2013-01-30 Thread Sohail Mirza
Thanks,
how can i update selenium-webdriver gem?  please


On Thu, Jan 31, 2013 at 1:27 AM, Željko Filipin zeljko.fili...@gmail.comwrote:

 On Wed, Jan 30, 2013 at 10:21 PM, Sohail Mirza mrz...@gmail.com wrote:

 from C:/Ruby193/lib/ruby/gems/1.9.1/gems/selenium-webdriver-2.27.2


 You have an old version of selenium-webdriver gem. Pleaseupdate it to
 2.29.0 and try again.

 Željko

 --
 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com

 ---
 You received this message because you are subscribed to the Google Groups
 Watir General group.
 To unsubscribe from this group and stop receiving emails from it, send an
 email to watir-general+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
Watir General group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




[wtr-general] Dynamic Objects Handling

2012-08-15 Thread Sohail Mirza
Hi,

I just wanted to know does *watir* gives us facility to handle dynamic
objects in the application?
For example i have HMTL table whose rows counts is not fixed and these rows
are created based on the search results returned.

I wanted to create script in such a way that no matters how many rows
created in table, it should retrieve the data from all rows's cell.

How i can i do that?


Thanks

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] Require 'rubygems'

2012-08-10 Thread Sohail Mirza
Hi,

what is the purpose of adding following line in the ruby program?

Require 'rubygems'

Thanks

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


Re: [wtr-general] Require 'rubygems'

2012-08-10 Thread Sohail Mirza
Thanks

Does the latest version of ruby automatically do this functionality or
still we need to require it?
Thanks for your comments

On Fri, Aug 10, 2012 at 3:00 PM, Željko Filipin zel...@filipin.eu wrote:

 On Fri, Aug 10, 2012 at 12:57 PM, Sohail Mirza mrz...@gmail.com wrote:
  what is the purpose of adding following line in the ruby program?
  Require 'rubygems'

 Require should be require. It makes sure that Ruby packet management
 system is required. You can not use any of the ruby gems (like watir) until
 rubygems is required. Some ruby installations do that by default, some not.

 Željko
 --
 filipin.eu

 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com


-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] How to save screenshot of IE Browser

2012-08-10 Thread Sohail Mirza
Hi,

I am automation a functionality in IE browser. I need to save the
screenshot of browser during script execution.
How can i do this?

Thanks

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] Issue in using Object Repositry

2012-08-04 Thread Sohail Mirza
Hi

I have defined Object Repository file as follow
-
*module LoginPage*
*  def username_textbox*
*  *
* return $ie.text_field(:id,i0116)*
*  end*
*
*
*  def UserPassword*
*return $ie.text_field(:id,i0118)*
*  end*
*
*
*  def SignIn*
*return $ie.button(:value,Sign in)*
*  end*
*
*
*end*
-

*But when i try to use above definition in other script file as follow*
-
username_textbox.set(record['UserName'])
-

I get the following error during execution
*
*
-
Error: test_login(Login)
  NoMethodError: undefined method `text_field' for nil:NilClass
D:/DavidBrown/ObjRep/LoginPage.rb:4:in `username_textbox'
 1: module LoginPage
 2:   def username_textbox
 3:
  = 4: return $ie.text_field(:id,i0116)
 5:
 6:   end
 7:
LoginUsingObjRep.rb:24:in `block in test_login'
LoginUsingObjRep.rb:21:in `each'
LoginUsingObjRep.rb:21:in `test_login'
-

Kindly advise what is wrong in above code?
Thanks

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] Watir Version

2012-08-01 Thread Sohail Mirza
Hi,

What are the different versions of Watir available?
i just tried following and somehow come to know that watir version 1 is
installed on my machine. Is it the latest one?
*
*
*C:\ruby -e 'require watir; puts Watir::IE::VERSION'*
*-e:1:in `main': uninitialized constant Watir::IE::VERSION (NameError)*

Thanks

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] David Brown's Excel Interface issue

2012-08-01 Thread Sohail Mirza
Hi,

I downloaded XLS.ZIP excel file from the
http://wiki.openqa.org/display/WTR/Excel+interface+class
i extracted this code to D: drive.

Then using command prompt, i entered ruby ruby XLS_usage_example.rb and
pressed enter...
immediately i got following error

C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in
`require':
cannot load such file -- Xls (LoadError)
from
C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:i
n `require'
from XLS_usage_example.rb:2:in `main'


*Please let me know what is wrong???*
Thanks

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] Re: David Brown's Excel Interface issue

2012-08-01 Thread Sohail Mirza
its resolved..

I had to copy Xls file at following location
C:\Ruby193\lib\ruby\1.9.1




On Wed, Aug 1, 2012 at 10:53 PM, Sohail Mirza mrz...@gmail.com wrote:

 Hi,

 I downloaded XLS.ZIP excel file from the
 http://wiki.openqa.org/display/WTR/Excel+interface+class
 i extracted this code to D: drive.

 Then using command prompt, i entered ruby ruby XLS_usage_example.rb and
 pressed enter...
 immediately i got following error

 C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in
 `require':
 cannot load such file -- Xls (LoadError)
 from
 C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:i
 n `require'
 from XLS_usage_example.rb:2:in `main'


 *Please let me know what is wrong???*
 Thanks


-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] NoMethodError: unknown property or method: `length' HRESULT error code:0x80020006

2012-07-31 Thread Sohail Mirza
Hi,

I tried to execute the following code but getting an error *NoMethodError:
unknown property or method: `length' HRESULT error code:0x80020006*

require watir
require test/unit
require win32ole

class TC_Login  Test::Unit::TestCase
$ie = Watir::IE.new

def setup
$ie.goto(http://gmail.com;)
end

def test_login
excel= WIN32OLE::new(excel.Application)
wrkbook=excel.Workbooks.Open(C:\\gmail.xls)
wrksheet = wrkbook.worksheets(1)
wrksheet.select
$username=wrksheet.cells(1,1)
$password=wrksheet.cells(2,1)
$ie.text_field(:id,Email).set($username)
$ie.text_field(:id,Passwd).set($password)
$ie.button(:name, 'signIn' ).click
end
end

*
*
*Error Details:*
test_login(TC_Login):
NoMethodError: unknown property or method: `length'
HRESULT error code:0x80020006
  Unknown name.
C:/Ruby193/lib/ruby/gems/1.9.1/gems/watir-classi
put_elements.rb:363:in `method_missing'
C:/Ruby193/lib/ruby/gems/1.9.1/gems/watir-classi
put_elements.rb:363:in `limit_to_maxlength'
C:/Ruby193/lib/ruby/gems/1.9.1/gems/watir-classi
put_elements.rb:336:in `type_by_character'
C:/Ruby193/lib/ruby/gems/1.9.1/gems/watir-classi
put_elements.rb:299:in `set'
delete.rb:16:in `test_login'

What is wrong in the code? Please can someone explain
Thanks

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] Diff b/w the way of instantiating an instance of BROWSER IE

2012-07-30 Thread Sohail Mirza
Hi,



1 - What is the difference between following two lines.

* *

*browser = Watir::Browser.new*

*ie = Watir::IE.new*





Thanks,

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] Contains_Text vsText_Included?

2012-07-30 Thread Sohail Mirza
Hi,



1 - What is the difference between following two validation methods.

* *

*Contains_Text*

*Text_Included*





Thanks

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


Re: [wtr-general] Contains_Text vsText_Included?

2012-07-30 Thread Sohail Mirza
Željko,

Both are deprecated 
Then which method is now being used to validate particular text string /
message on browser screen???
Where i can find information about all deprecated methods?

Thanks

On Mon, Jul 30, 2012 at 11:34 PM, Željko Filipin zel...@filipin.eu wrote:

 On Mon, Jul 30, 2012 at 9:20 PM, Sohail Mirza mrz...@gmail.com wrote:
  1 - What is the difference between following two validation methods.
  Contains_Text
  Text_Included

 I think both are deprecated.

 Željko
 --
 filipin.eu

 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com


-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] Watir Framework?

2012-07-28 Thread Sohail Mirza
Hi,

I just wanted to know which is the best Watir Framework for automating web
application? Any example available on github?
Which is the best IDE for Watir script development?

Thanks
Sohail

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


Re: [wtr-general] Watir Framework?

2012-07-28 Thread Sohail Mirza
Željko Thanks for your comment...

Could you more explain page-object gem? How to setup page-object gem?
Could you give some link reference where i can find more details about
page-object gem?

Thanks


On Sat, Jul 28, 2012 at 5:14 PM, Željko Filipin zel...@filipin.eu wrote:

 On Sat, Jul 28, 2012 at 3:11 PM, Sohail Mirza mrz...@gmail.com wrote:
  I just wanted to know which is the best Watir Framework for automating
 web application? Any example available on github?
 I could not guarantee that it is the best, but I prefer page-object gem:

 https://github.com/cheezy/page-object


  Which is the best IDE for Watir script development?

 I use rubymine:

 http://www.jetbrains.com/ruby/

 Željko
 --
 filipin.eu

 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com


-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


Re: [wtr-general] Watir Framework?

2012-07-28 Thread Sohail Mirza
seems not able to get the point from where to start... do you have
something to help me out on this...

I wanted to have following folder structure

ObjectRepositry (should contains object repositry file and i have no idea
how to make OR here in watir)
Library (should contains library code)
Data (should contains data file)
Reports (should contains reports)
Run.rb to run all the file

Thanks

On Sat, Jul 28, 2012 at 5:31 PM, Željko Filipin zel...@filipin.eu wrote:

 On Sat, Jul 28, 2012 at 3:30 PM, Sohail Mirza mrz...@gmail.com wrote:
  Could you more explain page-object gem? How to setup page-object gem?
  Could you give some link reference where i can find more details about
 page-object gem?

 https://github.com/cheezy/page-object
 https://github.com/cheezy/page-object/wiki
 https://leanpub.com/cucumber_and_cheese

 Željko

 --
 Before posting, please read http://watir.com/support. In short: search
 before you ask, be nice.

 watir-general@googlegroups.com
 http://groups.google.com/group/watir-general
 watir-general+unsubscr...@googlegroups.com


-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] WatiR Recorder++

2010-06-23 Thread Sohail Mirza
Hi All,

Can anyone explain me below points

*How to installed Watir Recorder ++?*
*What is the difference between WatiR Recorder++ and WatiR Maker?*


Best Regards,
Sohail

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

You received this message because you are subscribed to 
http://groups.google.com/group/watir-general
To post: watir-general@googlegroups.com
To unsubscribe: watir-general+unsubscr...@googlegroups.com