Search
 
 

Display results as :
 


Rechercher Advanced Search

Latest topics
» how to connect DB in selenium webriver
Fri Oct 06, 2017 4:09 pm by anbarasi

» How find any text in browser screen and click on it?
Thu Oct 05, 2017 2:02 pm by sandeepkommineni

» Selenium Webdriver
Tue Oct 03, 2017 1:35 pm by PiyushBiswas

» GRID setup tutorial.
Wed Sep 27, 2017 4:29 pm by johnyapp

» Drag & Drop Between Windows Using Selenium Driver
Wed Sep 27, 2017 2:10 pm by 26rondel

» Check if window is closed / verify input
Sat Sep 23, 2017 10:21 pm by brainstir

» How to work on pages with AJAX in selenium?
Mon Sep 18, 2017 6:08 pm by azharuddin

» pause test until user press a key like F2
Wed Aug 09, 2017 11:10 pm by djnforce

» Selecting the input for auto populating element
Sat Jul 29, 2017 7:53 pm by kdabbara

Navigation
 Portal
 Index
 Memberlist
 Profile
 FAQ
 Search

File type validation

View previous topic View next topic Go down

File type validation

Post by Archana on Wed Aug 26, 2009 9:28 pm

Hi,
I have set “signed.applets.codebase_principal_support” set to the value “true” in my Mozilla.

In my selenium IDE, the below testcase (HTML format) is running fine.
type | trophy_image | C:\Documents and Settings\Administrator\Desktop\1.txt
click | submit
waitForAlert | Invalid Image file

But, Equivalent PHP-sel RC testcase is giving exception when I run in iexplore (In mozilla, its fine)

$this->type("trophy_image", "C:\\Documents and Settings\\Administrator\\Desktop\\1.txt");
$this->click("submit");
for ($second = 0; ; $second++) {
if ($second >= 60) $this->fail("timeout");
try {
if ("Invalid image file"== $this->getAlert()) break;
} catch (Exception $e) {}
sleep(1);
}

is giving timeout.

What's the problem here? I think as it is security issue, IE is not allowing to type in to text field. How to solve this issue?
avatar
Archana
Regular Participant
Regular Participant

Posts : 33
Join date : 2009-08-21

Back to top Go down

Re: File type validation

Post by Archana on Mon Aug 31, 2009 8:03 pm

Pls do reply any one! Thanks in advance.
avatar
Archana
Regular Participant
Regular Participant

Posts : 33
Join date : 2009-08-21

Back to top Go down

Re: File type validation

Post by Archana on Fri Sep 11, 2009 7:02 pm

Hi, Any ideas to solve my problem? Sad
avatar
Archana
Regular Participant
Regular Participant

Posts : 33
Join date : 2009-08-21

Back to top Go down

Re: File type validation

Post by nellorekrishnakumar on Sat Sep 12, 2009 12:49 pm

Hi Archana,

Selenium performance in IE is slow when compared to firefox , try to put wait command and try to execute ur script in selenium.

Thanks,
Nellore Krishna Kumar

nellorekrishnakumar
Active particpant
Active particpant

Posts : 19
Join date : 2009-08-14
Age : 32
Location : HYDERABAD

Back to top Go down

Re: File type validation

Post by mugenhere on Mon Sep 14, 2009 2:01 am

Did you try printing $this->getAlert()? Try that inside the loop to see what is being compared with what.
The value you are comparing it with might differ slightly or maybe the value is not being fetched from the page.

Some code suggestions: 1)It seems you need a do-while/while loop
2) ($this->getAlert() == "Invalid image file") is more readable than (Invalid image file"== $this->getAlert())

mugenhere

Posts : 9
Join date : 2009-09-08

Back to top Go down

Re: File type validation

Post by Sponsored content


Sponsored content


Back to top Go down

View previous topic View next topic Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum