2

In TestNG I am returning two Dimensional object[][],where StaticVariable.channel_id.get(i) returns dynamic string value.

But when I am trying to perform any operation on that string,which coming as parameter from this dataprovider,It's came with [channel_id], eg -[asda1ds216adsasda] and when i am performing URI request it becomes

http://www.example.com/channels/[asdad21321]

it should be http://www.example.com/channels/asdad21321

@DataProvider(name="get_channel1")
    public static Object[][] createData4(){
        Object[][] object = new Object[StaticVariable.channel_id.size()][3];
        for (int i = 0; i < StaticVariable.channel_id.size(); i++) 
        {       
            object[i][0] = StaticVariable.channel_id.get(i);                            
            object[i][1] = new Integer(200);
            object[i][2] = "Pass";          
        }
        return object;  
}
Akash Shinde
  • 925
  • 3
  • 14
  • 31

0 Answers0