18 January 2026:


This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.



Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.

Dont understand How to configure Load Testing using Sahi Pro

Neil_123Neil_123 Members
edited March 2013 in Sahi Pro
Hi Guys,

I am bit confused with the noise.sah file and what i change to customise the Load Testing for my webpage.
I understand that I need to put in the steps I want to execute and measure in the subject.sah file however I dont understand what i need to do in the noise.sah file.
Do I just leave the existing content of the noise.sah file and add the steps that I want to execute?

For example Say I wanted to perform and measure performance on the following steps:

_setValue(_textbox("user"), "test");
_setValue(_password("password"), "secret");
_click(_submit("Login"));

I understand I need to put these in the subject.sah file. However what do I change in the noise.sah file?....do i leave all the existing text as shown below in the file and just add the same steps as I have in the subject.sah? ..I have added the steps at the bottom but am unsure whether these are correct ?

any help with this would be much appreciated

Thanks in advance

Neil

while(true) {
_navigateTo("/mywebpage/page.htm");

_doubleClick(_div("dbl click me"));
_assertEqual("[DOUBLE_CLICK]", _textarea("t2").value);
_click(_button("Clear"));

_doubleClick(_button("dbl click me"));
_assertEqual("[DOUBLE_CLICK]", _textarea("t2").value);
_click(_button("Clear"));

_click(_button("click me"));
_assertEqual("[CLICK]", _textarea("t2").value);
_click(_button("Clear"));

_rightClick(_div("right click me"));
_assertEqual("[RIGHT_CLICK]", _textarea("t2").value);
_click(_button("Clear"));

_rightClick(_button("right click me"));
_assertEqual("[RIGHT_CLICK]", _textarea("t2").value);
_click(_button("Clear"));

_click(_checkbox(0));
_assertTrue(_checkbox(0).checked);
if (_condition(_isIE() || _sahi.isSafariLike())){
_assertEqual("onclick_c1", _textarea("t2").value);
}else{
_assertEqual("onchange_c1", _textarea("t2").value);
}

_click(_checkbox(0));
_assertFalse(_checkbox(0).checked);


_click(_radio(0));
_assertTrue(_radio(0).checked);

if (_condition(_isIE() || _sahi.isSafariLike())){
_assertEqual("onclick_r1", _textarea("t2").value);
}else{
_assertEqual("onchange_r1", _textarea("t2").value);
}

_click(_radio(1));
_assertFalse(_radio(0).checked);
_assertTrue(_radio(1).checked);
}

while(true) {
_navigateTo("/mywebpage/page.htm");

_setValue(_textbox("user"), "test");
_setValue(_password("password"), "secret");
_click(_submit("Login"));


}

Answers

  • hai Neil_123 ,
    I too want to know the same. If u get the ans plz share..
  • Hello guys,

    This post is quite old - but i will reply to this for the sake of anyone else coming here,
    Say you have a file named Account_Sign_In.sah

    within this >

    we set a username,
    set a password
    and click login
    we assert for a successful login,
    and we log out.

    that essentially is you "subject.sah" - the file containing the steps you want to execute.

    Now, Noise.sah - does not need to be changed.
    This generate the "Load" as such -

    the execution would look like this :
    click on Bin on the Sahi Dashboard.

    type the following :

    dload.bat demo/load.noise.sah filepath/Account_Sign_In.sah http://www.website.com firefox

    So lets read that out -
    dload.bat requires parameters to run,

    these are,
    <filepath> noise.sah
    <filepath> the subject, in our case Account_Sign_In.sah
    a start URL
    and a browser

    there you go, i hope this helps
Sign In or Register to comment.