Wednesday, July 9, 2008

Interesting defect

This is about a defect I found in my application this morning.

The application was not tested for a month due to some requirements change. I was shifted to test some other products and finally I got my application back.
There were supposed to be lot of changes introduced as per client request.

My application has a login window as soon as it is launched.The login window has fields username & password and OK & Cancel buttons.Username: guest, password: guest

So, the first test is as follows:Enter guest in the username field and guadt in the password field.Click OK.Observed Behavior:A window with the message 'Incorrect username/password.' popped up.This window too had a OK button.
I clicked on OK and clicked again on OK button in the Login window.

As stated in slides 108 and 109, I wanted to test 'Error Handling'.I kept on pressing 'Enter' key in the keyboard.

This happened for more than 20 times and I was reminded of M.Bolton's statement in one of the post : 'Do the right thing after you have tried the incorrect thing' (Not the same words)

So, I thought of entering the correct credentials as I had tried enough of incorrect credentials and the application is not allowing me to enter.

I entered 'guest' in both the username and password fields.


The same window : 'Incorrect username/password' popped up.

I deleted the password and entered the password 'guest' again carefully and slowly.
Again the same message.I found something interesting here.

I went to the developer and asked whether they had changed the password and they replied 'NO'.

I closed the instance and opened a new instance.Entered 'guest' in both the fields and the application opened without any problem.
So, I realized that entering incorrect credentials and then entering correct credentials might reproduce this defect.

I tried entering incorrect credentials 10 times and the correct credentials at the 11th time. Application worked.
15 times, it worked.
20 times, it did not work, message popped up.
19 times, it worked.
21 times, it did not work, message popped up.

So, finally I logged a defect that 'After 20 incorrect logins, login with correct credentials also fails.'

Test Ideas that helped me find this defect:
Error Handling technique.
M.Bolton's statement.
Ben Simo's 'Failure' mnemonic

Have you ever come across such a defect?
Have you come across defects more interesting and wierd than this?

Please share the test ideas too as it may help others.

Scripted Testers:Would this defect be found by the execution of test case?

Feel free to question, discuss and comment.

Leia Mais…