MCPcopy Create free account
hub / github.com/tebeka/selenium / CurrentURL

Method CurrentURL

remote.go:612–624  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

610}
611
612func (wd *remoteWD) CurrentURL() (string, error) {
613 url := wd.requestURL("/session/%s/url", wd.id)
614 response, err := wd.execute("GET", url, nil)
615 if err != nil {
616 return "", err
617 }
618 reply := new(struct{ Value *string })
619 if err := json.Unmarshal(response, reply); err != nil {
620 return "", err
621 }
622
623 return *reply.Value, nil
624}
625
626func (wd *remoteWD) Get(url string) error {
627 requestURL := wd.requestURL("/session/%s/url", wd.id)

Callers 2

testFirefoxPreferencesFunction · 0.95
testFirefoxProfileFunction · 0.95

Calls 2

requestURLMethod · 0.95
executeMethod · 0.95

Tested by 2

testFirefoxPreferencesFunction · 0.76
testFirefoxProfileFunction · 0.76