How to create cookie using selenium? -


i want create cookie using selenium. have seen method supports selenium.createcookie(arg1,arg0), i'm bit confused arguments passed. can please give me example?

createcookie ( namevaluepair,optionsstring ) create new cookie path , domain same of current page under test, unless specified path cookie explicitly.

arguments:

  1. namevaluepair - name , value of cookie in format "name=value"

  2. optionsstring - options cookie. supported options include 'path' , 'max_age'. optionsstring's format "path=/path/, max_age=60". order of options irrelevant, unit of value of 'max_age' second.

source: selenium reference


Comments

Popular posts from this blog

jQuery clickable div with working mailto link inside -

java - Getting corefrences with Standard corenlp package -

WPF: binding viewmodel property of type DateTime to Calendar inside ItemsControl -