From 261d8747bd43e08e030875e1d40cfeb6d831dad8 Mon Sep 17 00:00:00 2001 From: hardya Date: Mon, 10 Mar 2008 12:22:08 +0000 Subject: [PATCH] In def test_01_edit_parties_screen_appears use a containing match for the supplier to cope with unusual naming of the edit link. In def test_02_edit_users use the 'next' link to find the SuppAgent1 user as they appear in the second page of results. Also, the second login is amended to SuppAdmin1. git-svn-id: http://locode01.ad.dom/svn/WEBMIP/trunk@3899 248e525c-4dfb-0310-94bc-949c084e9493 --- tests/user_management.rb | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/tests/user_management.rb b/tests/user_management.rb index ded7174..8b93273 100644 --- a/tests/user_management.rb +++ b/tests/user_management.rb @@ -23,7 +23,7 @@ #--- class Test_09_MIPADMIN_party_management< Test::Unit::TestCase # - #Test we can logon to the system using the webmip administrator user’s login credentials and check that + #Test we can logon to the system using the webmip administrator user�s login credentials and check that #all the fields required for creating parties in the system are correctly displayed. # def test_01_screen_appears @@ -570,7 +570,7 @@ class Test_11_edit_parties< Test::Unit::TestCase @@ie.wait #check market participant fields @@ie.select_list(:id,'P65_PRTY_TYPE').set('Market Participant') - @@ie.link(:name,'Edit Supplier1 SU1').click + @@ie.link(:name,/Edit Supplier1 SU1/).click @@ie.wait assert(@@ie.button(:value,'Cancel').exists?,'Could not find Cancel button(mktp fields)') assert(@@ie.button(:value,'Delete').exists?,'Could not find Delete button') @@ -639,6 +639,8 @@ class Test_11_edit_parties< Test::Unit::TestCase #edit a different user #@@ie.goto(EDIT_PARTIES) @@ie.select_list(:id,'P65_PRTY_TYPE').set('User') + @@ie.link(:text,/Next/).click + @@ie.wait @@ie.link(:name,'Edit SuppAgent1 ').click @@ie.wait @@ie.text_field(:id,'P66_TELEPHONE').set('01234 567899') @@ -665,7 +667,7 @@ class Test_11_edit_parties< Test::Unit::TestCase @@ie.goto(LOGIN) #we'll need to login as a SUPPADMIN user - login('Agent1','Passw0rd.') + login('SuppAdmin1','Passw0rd.') #Navigate to the page using the menu menu('Administration') @@ -680,7 +682,7 @@ class Test_11_edit_parties< Test::Unit::TestCase @@ie.wait assert(@@ie.contains_text('Action Processed.'),'Party not updated correctly') - @@ie.link(:name,'Edit SuppAgent1 ').click + @@ie.link(:name,/Edit SuppAgent1/).click @@ie.wait @@ie.text_field(:id,'P66_TELEPHONE').set('01234 567809') @@ie.button(:value,'Apply Changes').click