Forum Discussion

kamil's avatar
15 years ago

Login

Hi

I try to test a web application in ASP.NET

1. I write all steps with the TestComplete

2. Then I whant to write a script.

I write a script for a login:


function TestLoadTesting()


TestLoadTesting()

{


var i;


var sHeader;


var request;


var ti = LoadTesting.CreateTestInstance("New Created Test");


 


var aUsers = new Array(5);


 


//request = aUsers.Task.Connection(1).Request(4);


//request.RequestEventTrigger = true;


 


for(i = 0; i < aUsers.length; i++)


{


aUsers = LoadTesting.CreateVirtualUser("user " + i.toString());


aUsers.Task = LoadTesting.HTTPTaskByName("Task");


aUsers.TestInstance = ti;


 


sHeader = aUsers.Task.Connection(1).Request(4).RequestBody.contents;


aUsers.Task.Connection(1).Request(4).RequestBody.contents = aqString.Replace(sHeader, "admin1", "admin" + (i+1).toString());


ShowMessage(aUsers.Task.Connection(1).Request(4).RequestBody.contents);


sHeader='';


 


}


 


ti.Run("New result group");


}




After that I have a problem:

My script show me (with showmessage) that I gave all logins: admin1.. admin5

But in my database (Oracle) I saw that I connect just with admin1.



Can you help me with this?

I wrote all auto-updated parameters to my script


  • Hi Kamil,


    Let's continue working on the problem via e-mail in the support case you created.