{"id":33073872,"url":"https://github.com/seleniumQuery/seleniumQuery","last_synced_at":"2025-11-19T04:01:55.062Z","repository":{"id":9795206,"uuid":"11772284","full_name":"seleniumQuery/seleniumQuery","owner":"seleniumQuery","description":"jQuery-like cross-driver interface in Java for Selenium WebDriver","archived":false,"fork":false,"pushed_at":"2025-07-12T01:58:01.000Z","size":7874,"stargazers_count":72,"open_issues_count":2,"forks_count":25,"subscribers_count":10,"default_branch":"main","last_synced_at":"2025-10-28T13:39:11.912Z","etag":null,"topics":["java","jquery","selenium","selenium-webdriver","webdriver"],"latest_commit_sha":null,"homepage":"http://seleniumquery.github.io/","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/seleniumQuery.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2013-07-30T18:30:17.000Z","updated_at":"2025-02-24T09:00:45.000Z","dependencies_parsed_at":"2025-10-28T13:31:49.993Z","dependency_job_id":null,"html_url":"https://github.com/seleniumQuery/seleniumQuery","commit_stats":null,"previous_names":[],"tags_count":22,"template":false,"template_full_name":null,"purl":"pkg:github/seleniumQuery/seleniumQuery","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seleniumQuery%2FseleniumQuery","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seleniumQuery%2FseleniumQuery/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seleniumQuery%2FseleniumQuery/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seleniumQuery%2FseleniumQuery/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/seleniumQuery","download_url":"https://codeload.github.com/seleniumQuery/seleniumQuery/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seleniumQuery%2FseleniumQuery/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":285181688,"owners_count":27128334,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-11-19T02:00:05.673Z","response_time":65,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["java","jquery","selenium","selenium-webdriver","webdriver"],"created_at":"2025-11-14T10:00:27.822Z","updated_at":"2025-11-19T04:01:55.054Z","avatar_url":"https://github.com/seleniumQuery.png","language":"Java","readme":"# [seleniumQuery](http://seleniumquery.github.io)\n\n[![Maven Central](https://img.shields.io/maven-central/v/io.github.seleniumquery/seleniumquery.svg)](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22io.github.seleniumquery%22%20AND%20a%3A%22seleniumquery%22)\n\n\u003c!--\n[![Codacy Badge](https://api.codacy.com/project/badge/grade/6f25f5fe245746a4a7a53f426e0e1288)](https://www.codacy.com/app/acdcjunior/seleniumQuery)\n--\u003e\n[![codecov.io](https://codecov.io/gh/seleniumQuery/seleniumQuery/branch/master/graph/badge.svg)](https://codecov.io/gh/seleniumQuery/seleniumQuery)\n[![GitHub license](https://img.shields.io/badge/license-Apache%202-blue.svg)](https://raw.githubusercontent.com/seleniumQuery/seleniumQuery/master/LICENSE.txt)\n[![Join the chat at https://gitter.im/seleniumQuery/seleniumQuery](https://badges.gitter.im/seleniumQuery/seleniumQuery.svg)](https://gitter.im/seleniumQuery/seleniumQuery?utm_source=badge\u0026utm_medium=badge\u0026utm_campaign=pr-badge\u0026utm_content=badge)\n\n\u003c!--\n[![Build Status](https://travis-ci.org/seleniumQuery/seleniumQuery.svg?branch=master)](https://travis-ci.org/seleniumQuery/seleniumQuery)\n[![Windows Build Status](https://ci.appveyor.com/api/projects/status/mwvctg5o8ws7l7jg?svg=true)](https://ci.appveyor.com/project/acdcjunior/seleniumQuery/branch/master)\n[![Build status](https://codeship.com/projects/7b37d0c0-d5b4-0133-1efe-62329e93051f/status?branch=master)](https://codeship.com/projects/142644)\n[![wercker status](https://app.wercker.com/status/b772beb5c952865d659e548bf7d64f48/s \"wercker status\")](https://app.wercker.com/project/bykey/b772beb5c952865d659e548bf7d64f48)\n[![Circle CI](https://circleci.com/gh/seleniumQuery/seleniumQuery.svg?style=svg)](https://circleci.com/gh/seleniumQuery/seleniumQuery)\n--\u003e\n\n\u003c!--\n[![Run Status](https://api.shippable.com/projects/58b5bc1b1304cc0500e0c7b0/badge?branch=master)](https://app.shippable.com/github/seleniumQuery/seleniumQuery)\n\n[![Sauce Test Status](https://saucelabs.com/open_sauce/build_matrix/acdcjunior.svg)](https://saucelabs.com/u/acdcjunior)\n--\u003e\n\n### Feature-rich jQuery-like Java interface for Selenium WebDriver\n\nseleniumQuery is a feature-rich *cross-driver* Java library that brings a **jQuery-like** interface for [Selenium WebDriver](http://docs.seleniumhq.org/projects/webdriver/).\n\nIt is designed to be a **thin** layer over Selenium. You can use seleniumQuery to manage the WebDriver for you, or you can use seleniumQuery on top of your favorite selenium framework just\nto make some cases simpler when needed.\n\n### Example snippet:\n\n```java\n// Regular Selenium\nWebElement el  = driver.findElement(By.cssSelector(\".street\"));\nString oldStreet = element.getAttribute(\"value\"); // what if \".street\" is a \u003cselect\u003e? this won't work\nelement.setAttribute(\"value\", \"4th St!\")\n\n// seleniumQuery\n// getting the value\nString oldStreet = $(\".street\").val(); // works even if it is a \u003cselect\u003e, \u003ctextarea\u003e, etc.\n// setting the value\n$(\"input.street\").val(\"4th St!\"); // also would work for a \u003cselect\u003e\n```\n\nAnd much more. The example above is of something that has an equivalent in Selenium. Not everything does (many things would require tons of boilerplate in vanilla Selenium).\n\n### No special configuration needed - use seleniumQuery's goodies in your project right now:\n\nOn a regular `WebElement`...\n\n```java\n// an existing WebElement...\nWebElement existingWebElement = driver.findElement(By.id(\"myId\"));\n// call jQuery functions\nString elementVal = $(existingWebElement).val();\nboolean isButton = $(existingWebElement).is(\":button\"); // enhanced selector!\nfor (WebElement child: $(existingWebElement).children()) {\n  System.out.println(\"That element's child: \"+child);\n}\n```\n\nOr an existing `WebDriver`...\n\n```java\n// an existing WebDriver...\nWebDriver driver = new FirefoxDriver();\n// set it up\n$.driver().use(driver);\n// and use all the goods\nfor (WebElement e: $(\".myClass:contains('My Text!'):not(:button)\")) {\n  System.out.println(\"That element: \" + e);\n}\n```\n\n## What can you do with it?\n\nAllows querying elements by:\n\n- **CSS3 Selectors** - `$(\".myClass\")`, `$(\"#table tr:nth-child(3n+1)\")`;\n- **jQuery enhanced selectors** - `$(\":text:eq(3)\")`, `$(\".myClass:contains('My Text!')\")`;\n- **XPath** - `$(\"//div/*/label/preceding::*\")`;\n- and even some own **seleniumQuery selectors**: `$(\"#myOldDiv\").is(\":not(:present)\")`.\n\nBuilt using Selenium WebDriver's capabilities, no `jQuery.js` is embedded at the page, no side-effects are generated.\n\n\u003cbr\u003e\u003cbr\u003e\n\n# Quickstart: A running example\n\nTry it out now with the running example below:\n\n```java\nimport static io.github.seleniumquery.SeleniumQuery.$; // this will allow the short syntax\n\npublic class SeleniumQueryExample {\n  public static void main(String[] args) {\n    // The WebDriver will be instantiated only when first used\n    $.driver()\n        .useChrome() // sets Chrome as the driver (this is optional, if omitted, will default to HtmlUnit)\n        .headless() // configures chrome to be headless\n        .autoDriverDownload() // automatically downloads and configures chromedriver.exe\n        .autoQuitDriver(); // automatically quits the driver when the JVM shuts down\n\n    // or, instead, use any previously existing driver\n    // $.driver().use(myExistingInstanceOfWebDriver);\n\n    // starts the driver (if not started already) and opens the URL\n    $.url(\"http://www.google.com/?hl=en\");\n\n    // interact with the page\n    $(\":text[name='q']\").val(\"seleniumQuery\"); // the keys are actually typed!\n\n    // Besides the short syntax and the jQuery behavior you already know,\n    // other very useful function in seleniumQuery is .waitUntil(),\n    // handy for dealing with user-waiting actions (specially in Ajax enabled pages):\n\n    // the command below waits until the button is visible and then performs a real user click (not just the JS event)\n    $(\":button[value='Google Search']\").waitUntil().isVisible().then().click();\n\n    // this waits for the #resultStats to be visible using a selector and, when it is visible, returns its text content\n    String resultsText = $(\"#resultStats\").waitUntil().is(\":visible\").then().text();\n\n    // .assertThat() functions: fluently asserts that the text contains the string \"seconds\", ignoring case\n    $(\"#resultStats\").assertThat().text().containsIgnoreCase(\"seconds\");\n\n    System.out.println(resultsText);\n    // should print something like: About 4,100 results (0.42 seconds)\n\n    // $.quit(); // would quit the driver, but it is not needed as .autoQuitDriver() was used\n  }\n}\n```\n\nTo get the latest version of seleniumQuery, add to your **`pom.xml`**:\n\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003eio.github.seleniumquery\u003c/groupId\u003e\n    \u003cartifactId\u003eseleniumquery\u003c/artifactId\u003e\n    \u003cversion\u003e0.20.0\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n\n\n\u003cbr\u003e\u003cbr\u003e\n\n## Looking for more examples?\n\nDownload and execute the **[seleniumQuery showcase project](https://github.com/acdcjunior/seleniumQuery-showcase)**.\n It contains many demonstrations of what seleniumQuery is capable of.\n\n\u003cbr\u003e\n\n# Features\n\nseleniumQuery implements all jQuery functions that are useful to browser manipulation.\nOn top of it, we add many other useful functions (see `$(\"selector\").waitUntil()` and `$(\"selector\").assertThat()` below).\n \nOur main goal is to make emulating user actions and reading the state of pages easier than ever, with a consistent behavior across drivers.\n\n\n### Readable jQuery syntax you already know\n\nMake your code/tests more readable and easier to maintain. Leverage your knowledge of jQuery.\n\n```java\n// Instead of regular Selenium code:\nWebElement element = driver.findElement(By.id(\"mySelect\"));\nnew Select(element).selectByValue(\"ford\");\n\n// You can have the same effect writing just:\n$(\"#mySelect\").val(\"ford\");\n```\n\nGet to know what jQuery functions seleniumQuery supports and what else it brings to the table on our [seleniumQuery API wiki page](https://github.com/seleniumQuery/seleniumQuery/wiki/seleniumQuery-API).\n\n\u003cbr\u003e\n\n## Waiting (ajax testing) and asserting\n\n`WebDriver`'s `FluentWait` is great, but it requires too much boilerplate code. Enters the `.waitUntil()` function:\n\n```java\n// Below is an example of a \u003cdiv\u003e that should be hidden as effect of an Ajax call.\n// The code will hold until the modal is gone. If it is never gone, seleniumQuery will throw a timeout exception\n$(\"#modalDiv :button:contains('OK')\").click();\n$(\"#modalDiv :button:contains('OK')\").waitUntil().is(\":not(:visible)\");\n// Or the two commands above, fluently:\n$(\"#modalDivOkButton\").click().waitUntil().is(\":not(:visible)\");\n```\n\nYou can also **assert** directly into the seleniumQuery object using `.assertThat()`:\n\n```java\n$(\"#modalDiv :button:contains('OK')\").assertThat().is(\":not(:visible)\");\n$(\"#myInput\").assertThat().val().isBlank();\n```\n\n*Any* function that can be used with `$().waitUntil()` can also be used with `$().assertThat()` and vice-versa.\nSee below, expand (click on the arrow) each item for more details.\n\n\u003ctable\u003e\n\u003ctr\u003e\n    \u003cth\u003e$(). function\u003c/th\u003e\n    \u003cth\u003eProperty/Evaluation Function\u003c/th\u003e\n    \u003cth\u003eEvaluation Function\u003c/th\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd rowspan=\"2\"\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.waitUntil()\u003c/code\u003e\u003c/summary\u003e\n\nIn order to handle interactions with Ajax-enabled pages, you can use the `.waitUntil()` function:\n\n- The `.waitUntil()` functions will *requery* the DOM for the elements until the given condition is met, returning a **new** seleniumQuery object when that happens.\n\n```java\n// .waitUntil() will requery the DOM every time until the matched set fulfills the requirements\n\n// .is() functions\n$(\".aDivDiv\").waitUntil().is(\":present\");\n$(\".myInput\").waitUntil().is(\":enabled\");\n$(\".aDivDiv\").waitUntil().is(\":visible\");\n$(\".myInput\").waitUntil().is(\":visible:enabled\");\n// functions such as .val(), .text() and others are also available\n$(\".myInput\").waitUntil().val().isEqualTo(\"expectedValue\");\n$(\".aDivDiv\").waitUntil().text().contains(\"expectedText\");\n// and more...\n$(\".myInput\").waitUntil().val().matches(\".*\\d{10}\\*\");\n$(\".myInput\").waitUntil().size().isGreaterThan(7);\n$(\".aDivDiv\").waitUntil().html().contains(\"\u003cdiv\u003eexpected\u003c/div\u003e\");\n```\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.assertThat()\u003c/code\u003e\u003c/summary\u003e\n\nAsserts, fluently, that the function has a specified value or matches a specified condition.\n\n```java\n$(\"#stuff\").assertThat().val().isEqualTo(\"expectedValue\");\n$(\".m-e\").assertThat().attr(\"attrName\").isEqualTo(\"expectedValue\");\n$(\"span\").assertThat().size().isGreaterThan(7);\n$(\"#age\").assertThat().val().matches(\".*\\d{10}\\*\");\n$(\"#ipt\").assertThat().val().matches(value -\u003e value.length() \u003e 50)\n```\n\n\u003c/details\u003e\n\u003c/td\u003e\n\u003ctd\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.val()\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".myInput\").assertThat().val().isEqualTo(\"expectedValue\");\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.text()\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".div\").assertThat().text().isEqualTo(\"expectedValue\");\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.attr(\"attrName\")\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".myInput\").assertThat().attr(\"attrName\").isEqualTo(\"expectedValue\");\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.prop(\"propName\")\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".myInput\").assertThat().prop(\"propName\").isEqualTo(\"expectedValue\");\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.html()\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".div\").assertThat().html().isEqualTo(\"expectedValue\");\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.size()\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".div\").assertThat().size().isEqualTo(0);\n\n\u003c/details\u003e\n\u003c/td\u003e\n\u003ctd\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.isEqualTo(\"string\" | \u0026lt;number\u003e | other)\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".myInput\").assertThat().val().isEqualTo(\"expectedValue\");\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.isBlank()\u003c/code\u003e\u003c/summary\u003e\n\nTests if the result of the preceding function \u003cb\u003eis empty (`\"\"`), `null` or whitespace only\u003c/b\u003e:\n\n    (null).isBlank()      = true\n    (\"\").isBlank()        = true\n    (\" \").isBlank()       = true\n    (\"bob\").isBlank()     = false\n    (\"  bob  \").isBlank() = false\n\nExample:\n\n    $(\".myInput\").assertThat().text().isBlank();\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.isGreaterThan(\u0026lt;number\u003e)\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".myInput\").assertThat().size().isGreaterThan(7);\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.isLessThan(\u0026lt;number\u003e)\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".myInput\").assertThat().size().isGreaterThan(7);\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.contains(\"string\")\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".aDivDiv\").waitUntil().html().contains(\"\u003cdiv\u003eexpected\u003c/div\u003e\");\n    $(\".aDivDiv\").assertThat().text().contains(\"expectedText\");\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.containsIgnoreCase(\"string\")\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".aDivDiv\").assertThat().text().containsIgnoreCase(\"eXpeCTedText\");\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.matches(\"string regex\")\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".myInput\").assertThat().val().matches(\".*\\d{10}\\*\");\n    $(\"...\").waitUntil().html().matches(\"my[0-9]regex.*?\");\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.matches(java.util.Pattern)\u003c/code\u003e\u003c/summary\u003e\n\n    $(\"...\").assertThat().val().matches(java.util.Pattern);\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.matches(\u0026lt;Hamcrest Matcher\u003e)\u003c/code\u003e\u003c/summary\u003e\n\n    $(\"#myDiv\").waitUntil().text().matches(Matchers.containsString(\"John\"));\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.matches(\u0026lt;lambda predicate\u003e)\u003c/code\u003e\u003c/summary\u003e\n\n```java\n$(\"#ipt\").waitUntil().val().matches(value -\u003e value.length() \u003e 50)\n```\n\n\u003c/details\u003e\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd colspan=\"2\"\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.is(\"selector\")\u003c/code\u003e\u003c/summary\u003e\n\n    $(\".myInput\").assertThat().is(\":disabled\");\n    $(\".myInput\").assertThat().is(\":visible:enabled\");\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.isEmpty()\u003c/code\u003e\u003c/summary\u003e\n\nEvaluates if the size of this seleniumQuery is equal to zero.\n     \n     $(\"div\").waitUntil().isEmpty();\n     $(\"div\").assertThat().isEmpty();\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.isNotEmpty()\u003c/code\u003e\u003c/summary\u003e\n\nEvaluates if the size of this seleniumQuery is greated than zero.\n     \n     $(\"div\").waitUntil().isNotEmpty();\n     $(\"div\").assertThat().isNotEmpty();\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.isPresent()\u003c/code\u003e\u003c/summary\u003e\n\nEvaluates if this seleniumQuery object has elements (is not empty).\n\nNote: this is an alias to `.isNotEmpty()`.\n     \n     $(\"div\").waitUntil().isPresent();\n     $(\"div\").assertThat().isPresent();\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.isVisible()\u003c/code\u003e\u003c/summary\u003e\n\nEvaluates if this seleniumQuery object has \u003cb\u003eonly visible\u003c/b\u003e elements.\n\nNote: this is different from `.is(\":visible\")` because `.is()` requires only one\n    element to match the selector (to be visible), whereas this `.isVisible()` method\n    requires \u003cb\u003eall\u003c/b\u003e matched elements to be visible.\n\n    $(\"span.all-visible\").waitUntil().isVisible();\n    $(\"span.all-visible\").assertThat().isVisible();\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.isDisplayed()\u003c/code\u003e\u003c/summary\u003e\n\nEvaluates if this seleniumQuery object has \u003cb\u003eonly visible\u003c/b\u003e elements.\n\nNote: this is different from `.is(\":visible\")` because `.is()` requires only one\n    element to match the selector (to be visible), whereas this `.isVisible()` method\n    requires \u003cb\u003eall\u003c/b\u003e matched elements to be visible.\n\nThis is an alias to `.isVisible()`.\n\n    $(\"span.all-visible\").waitUntil().isDisplayed();\n    $(\"span.all-visible\").assertThat().isDisplayed();\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.isHidden()\u003c/code\u003e\u003c/summary\u003e\n\nEvaluates if this seleniumQuery object is \u003cb\u003enot empty\u003c/b\u003e and has \u003cb\u003eonly hidden\u003c/b\u003e elements.\n\nNote: while `.isNotVisible()` considers an empty set a success, this method doesn't.\n\n    $(\"span.non-empty-and-all-hidden\").waitUntil().isHidden();\n    $(\"span.non-empty-and-all-hidden\").assertThat().isHidden();\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.isNotVisible()\u003c/code\u003e\u003c/summary\u003e\n\nEvaluates if this seleniumQuery object is \u003cb\u003eempty\u003c/b\u003e or has \u003cb\u003eonly hidden\u003c/b\u003e elements.\n\nNote: while `.isHidden()` considers an empty set a failure, this method doesn't.\n\n    $(\"span.empty-or-all-hidden\").waitUntil().isNotVisible();\n    $(\"span.empty-or-all-hidden\").assertThat().isNotVisible();\n\n\u003c/details\u003e\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003c/table\u003e\n\nYou can also chain calls using `.and()`:\n\n    $(\"span\").assertThat().size().isGreaterThan(5).and().text().isEqualTo(\"a b c d e\");\n    \nOr use functions after waiting/asserting using `.then()`:\n\n    $(\"#div\").waitUntil().isVisible().then().click();\n\n\u003cbr\u003e\u003cbr\u003e\n\n\n## Flexible WebDriver builder system\n\nHow to setup the `WebDriver`? Simply use our builder. You can download [their executables](https://github.com/SeleniumHQ/selenium/wiki/ChromeDriver) before or you can\nlet seleniumQuery automatically download and configure them. Setup in seleniumQuery is all too easy:\n \n```java\n// Using Chrome, general example:\n$.driver()\n    .useChrome() // configures Chrome as the driver\n    .headless() // configures Chrome to run in headless mode\n    .autoDriverDownload() // automatically downloads and configures chromedriver.exe\n    .autoQuitDriver(); // automatically quits the driver when the JVM shuts down\n\n// Using Firefox\n$.driver()\n    .useFirefox() // configures Firefox as the driver\n    .headless() // configures Firefox to run in headless mode\n    .autoDriverDownload() // automatically downloads and configures geckodriver.exe\n    .autoQuitDriver(); // automatically quits the driver when the JVM shuts down\n```\n\nFor more examples, options and all supported drivers, see table below.\n\n\u003ctable\u003e\n\u003ctr\u003e\n\u003ctd\u003e\n\n![Existing WebDriver Instance](doc/webdriver.png)\u003c/td\u003e\u003ctd\u003e\n\n### Using seleniumQuery in an ***existing*** `WebDriver` instance\n\nThe driver builder functions are a bonus, you don't *have* to use them. For seleniumQuery, it makes no difference.\n\nIf you want to create the `WebDriver` yourself or **add seleniumQuery to an existing `WebDriver` instance** just:\n\n```java\nWebDriver myExistingDriverInstance = ...; // created elsewhere by whoever\n\n$.driver().use(myExistingDriverInstance); // from now on, $ will work on myExistingDriverInstance\n\n// now you can use all of seleniumQuery's power!\n$(\"#phone\").assertThat().val().isEqualTo(\"99887766\");\n```\n\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\n\n![chrome](doc/chrome.png)\u003c/td\u003e\u003ctd\u003e\n\n### Chrome\n\nHere's how seleniumQuery can simplify a `ChromeDriver` instantiation.\n\n**Headless** mode available. **Automatic driver download** available.\n\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.useChrome()\u003c/code\u003e\u003c/summary\u003e\n\nConfigures Chrome as the driver to be used. Provides additional configuration options that can be chained.\n\nCalling `$.driver().useChrome()` does not instantiate the driver right away, it merely configures it.\nThe driver will be instantiated when first used only (e.g. when `$.url(\"http://somepage\")` is called).\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.headless()\u003c/code\u003e\u003c/summary\u003e\n\nRuns Chrome in headless mode.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoQuitDriver()\u003c/code\u003e\u003c/summary\u003e\n\nAutomatically quits the driver upon JVM shutdown.\n\nIf you don't use `.autoQuitDriver()`, you can quit the driver calling `$.quit()`.\n\nHaving `.autoQuitDriver()` on and still calling `$.quit()` makes no harm, so quit at will. \n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoDriverDownload()\u003c/code\u003e\u003c/summary\u003e\n\nseleniumQuery automatically downloads and configures the driver. The download is managed by [webdrivermanager](https://github.com/bonigarcia/webdrivermanager).\nAdditional options are available, pass a lambda to `.autoDriverDownload(\u003clabda\u003e)` to be able to configure:\n\n```java\n$.driver().useChrome().autoDriverDownload((BrowserManager configurer) -\u003e {\n    // se more options at https://github.com/bonigarcia/webdrivermanager#webdrivermanager-api\n    configurer.proxy(\"http://corpproxy:8182\");\n    configurer.proxyUser(\"myUser\");\n    configurer.proxyPass(\"myPass\")\n});\n```\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withOptions(ChromeOptions)\u003c/code\u003e\u003c/summary\u003e\n\nEnables additional configuration through a `ChromeOptions` instance.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withPathToChromeDriver(String)\u003c/code\u003e\u003c/summary\u003e\n\nIf you don't want seleniumQuery to automatically download the executable for you (using `.autoDriverDownload()`) you can\nspecify the location of `chromedriver.exe`/`chromedriver` yourself:\n\n```java\n$.driver().useChrome().withPathToChromeDriver(\"path/to/chromedriver.exe\");\n```\n\nIf you use neither `.autoDriverDownload()` nor `.withPathToChromeDriver()`, seleniumQuery will attempt to find the executable\non your PATH or classpath. If it doesn't find it anywhere, an exception will be thrown.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withCapabilities(DesiredCapabilities)\u003c/code\u003e\u003c/summary\u003e\n\nConfigures the given `DesiredCapabilities` in the driver to be instantiated. Prefer `ChromeOptions` when possible.\n\n\u003c/details\u003e\n\n\u003cbr\u003e\n\n```java\n// Using Chrome\n$.driver().useChrome(); // will look for chromedriver/exe to you, including in the classpath!\n// if you don't have chromedriver.exe and want seleniumQuery to auto download and configure it\n$.driver().useChrome().headless().autoDriverDownload();\n// If you want to set the path to chromedriver.exe yourself\n$.driver().useChrome().withPathToChromeDriver(\"path/to/chromedriver.exe\")\n// General example:\n$.driver()\n    .useChrome() // configures Chrome as the driver\n    .headless() // configures Chrome to run in headless mode\n    .autoDriverDownload() // automatically downloads and configures chromedriver.exe\n    .autoQuitDriver(); // automatically quits the driver when the JVM shuts down\n// using options\n$.driver()\n    .useChrome()\n    .withOptions(\u003csome ChromeOptions instance\u003e)\n```\n\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\n\n![firefox](doc/firefox.png)\u003c/td\u003e\u003ctd\u003e\n\n### Firefox\n\nEasy `FirefoxDriver` instantiation and configuration with seleniumQuery.\n\n**Headless** mode available. **Automatic driver download** available.\n\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.useFirefox()\u003c/code\u003e\u003c/summary\u003e\n\nConfigures Firefox as the driver to be used. Provides additional configuration options that can be chained.\n\nCalling `$.driver().useFirefox()` does not instantiate the driver right away, it merely configures it.\nThe driver will be instantiated when first used only (e.g. when `$.url(\"http://somepage\")` is called).\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.headless()\u003c/code\u003e\u003c/summary\u003e\n\nRuns Firefox in headless mode.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoQuitDriver()\u003c/code\u003e\u003c/summary\u003e\n\nAutomatically quits the driver upon JVM shutdown.\n\nIf you don't use `.autoQuitDriver()`, you can quit the driver calling `$.quit()`.\n\nHaving `.autoQuitDriver()` on and still calling `$.quit()` makes no harm, so quit at will. \n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoDriverDownload()\u003c/code\u003e\u003c/summary\u003e\n\nseleniumQuery automatically downloads and configures the driver. The download is managed by [webdrivermanager](https://github.com/bonigarcia/webdrivermanager).\nAdditional options are available, pass a lambda to `.autoDriverDownload(\u003clabda\u003e)` to be able to configure:\n\n```java\n$.driver().useFirefox().autoDriverDownload((BrowserManager configurer) -\u003e {\n    // se more options at https://github.com/bonigarcia/webdrivermanager#webdrivermanager-api\n    configurer.proxy(\"http://corpproxy:8182\");\n    configurer.proxyUser(\"myUser\");\n    configurer.proxyPass(\"myPass\")\n});\n```\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withOptions(FirefoxOptions)\u003c/code\u003e\u003c/summary\u003e\n\nEnables additional configuration through a `FirefoxOptions` instance.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withBinary(FirefoxBinary)\u003c/code\u003e\u003c/summary\u003e\n\nEnables additional configuration through a `FirefoxBinary` instance.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withProfile(FirefoxProfile)\u003c/code\u003e\u003c/summary\u003e\n\nEnables additional configuration through a `FirefoxProfile` instance.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withCapabilities(DesiredCapabilities)\u003c/code\u003e\u003c/summary\u003e\n\nConfigures the given `DesiredCapabilities` in the driver to be instantiated. Prefer `FirefoxOptions` when possible.\n\n\u003c/details\u003e\n\n\u003cbr\u003e\n\n```java\n// Using Firefox\n$.driver()\n    .useFirefox() // configures Firefox as the driver\n    .headless() // configures Firefox to run in headless mode\n    .autoDriverDownload() // automatically downloads and configures geckodriver.exe\n    .autoQuitDriver(); // automatically quits the driver when the JVM shuts down\n// simplified setting of profile, options and binary\n$.driver()\n    .useFirefox()\n    .withProfile(\u003can instance of FirefoxProfile\u003e)\n    .withOptions(\u003can instance of FirefoxOptions\u003e)\n    .withBinary(\u003can instance of FirefoxBinary\u003e);\n```\n\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\n\n![opera](doc/opera.png)\u003c/td\u003e\u003ctd\u003e\n\n### Opera\n\n **Automatic driver download** available.\n\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.useOpera()\u003c/code\u003e\u003c/summary\u003e\n\nConfigures Opera as the driver to be used. Provides additional configuration options that can be chained.\n\nCalling `$.driver().useOpera()` does not instantiate the driver right away, it merely configures it.\nThe driver will be instantiated when first used only (e.g. when `$.url(\"http://somepage\")` is called).\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoQuitDriver()\u003c/code\u003e\u003c/summary\u003e\n\nAutomatically quits the driver upon JVM shutdown.\n\nIf you don't use `.autoQuitDriver()`, you can quit the driver calling `$.quit()`.\n\nHaving `.autoQuitDriver()` on and still calling `$.quit()` makes no harm, so quit at will. \n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoDriverDownload()\u003c/code\u003e\u003c/summary\u003e\n\nseleniumQuery automatically downloads and configures the driver. The download is managed by [webdrivermanager](https://github.com/bonigarcia/webdrivermanager).\nAdditional options are available, pass a lambda to `.autoDriverDownload(\u003clabda\u003e)` to be able to configure:\n\n```java\n$.driver().useOpera().autoDriverDownload((BrowserManager configurer) -\u003e {\n    // se more options at https://github.com/bonigarcia/webdrivermanager#webdrivermanager-api\n    configurer.proxy(\"http://corpproxy:8182\");\n    configurer.proxyUser(\"myUser\");\n    configurer.proxyPass(\"myPass\")\n});\n```\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withOptions(OperaOptions)\u003c/code\u003e\u003c/summary\u003e\n\nEnables additional configuration through a `OperaOptions` instance.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withBinary(string | File)\u003c/code\u003e\u003c/summary\u003e\n\nConfigures the Opera browser binary location. Example:\n\n```java\n$.driver().useOpera().autoDriverDownload()\n    .withBinary(\"C:/Program Files/Opera/49.0.2725.47/opera.exe\");\n```\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withCapabilities(DesiredCapabilities)\u003c/code\u003e\u003c/summary\u003e\n\nConfigures the given `DesiredCapabilities` in the driver to be instantiated. Prefer `OperaOptions` when possible.\n\n\u003c/details\u003e\n\n\u003cbr\u003e\n\n```java\n// Opera\n// we'll download the driver for you\n$.driver().useOpera().autoDriverDownload();\n// simplified setting of options and binary\n$.driver()\n    .useOpera()\n    .withOptions(\u003can instance of OperaOptions\u003e)\n    .withBinary(\"C:/Program Files/Opera/49.0.2725.47/opera.exe\") // example path\n    .autoDriverDownload();\n```\n\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\n\n![PhantomJS](doc/phantomjs.png)\u003c/td\u003e\u003ctd\u003e\n\n### PhantomJS\n\n**Always headless**, webkit-based. **Automatic executable download** available.\n\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.usePhantomJS()\u003c/code\u003e\u003c/summary\u003e\n\nConfigures PhantomJS as the driver to be used. Provides additional configuration options that can be chained.\n\nCalling `$.driver().usePhantomJS()` does not instantiate the driver right away, it merely configures it.\nThe driver will be instantiated when first used only (e.g. when `$.url(\"http://somepage\")` is called).\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoQuitDriver()\u003c/code\u003e\u003c/summary\u003e\n\nAutomatically quits the driver upon JVM shutdown.\n\nIf you don't use `.autoQuitDriver()`, you can quit the driver calling `$.quit()`.\n\nHaving `.autoQuitDriver()` on and still calling `$.quit()` makes no harm, so quit at will. \n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoDriverDownload()\u003c/code\u003e\u003c/summary\u003e\n\nseleniumQuery automatically downloads and configures the driver. The download is managed by [webdrivermanager](https://github.com/bonigarcia/webdrivermanager).\nAdditional options are available, pass a lambda to `.autoDriverDownload(\u003clabda\u003e)` to be able to configure:\n\n```java\n$.driver().usePhantomJS().autoDriverDownload((BrowserManager configurer) -\u003e {\n    // se more options at https://github.com/bonigarcia/webdrivermanager#webdrivermanager-api\n    configurer.proxy(\"http://corpproxy:8182\");\n    configurer.proxyUser(\"myUser\");\n    configurer.proxyPass(\"myPass\")\n});\n```\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withPathToPhantomJS(String)\u003c/code\u003e\u003c/summary\u003e\n\nIf you don't want seleniumQuery to automatically download the executable for you (using `.autoDriverDownload()`) you can\nspecify the location of `phantomjs.exe`/`phantomjs` yourself:\n\n```java\n$.driver().usePhantomJS().withPathToPhantomJS(\"path/to/phantomjs.exe\");\n```\n\nIf you use neither `.autoDriverDownload()` nor `.withPathToPhantomJS()`, seleniumQuery will attempt to find the executable\non your PATH or classpath. If it doesn't find it anywhere, an exception will be thrown.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withCapabilities(DesiredCapabilities)\u003c/code\u003e\u003c/summary\u003e\n\nConfigures the given `DesiredCapabilities` in the driver to be instantiated.\n\n\u003c/details\u003e\n\n\u003cbr\u003e\n\n```java\n// PhantomJS (GhostDriver)\n// we'll download phantomjs.exe for you\n$.driver().usePhantomJS().autoDriverDownload();\n// or, we may find phantomjs[.exe] for you, throwing an error if not present\n$.driver().usePhantomJS();  \n// Or you may set the path yourself\n$.driver().usePhantomJS().withPathToPhantomJS(\"path/to/phantomjs.exe\");\n```\n\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\n\n![HtmlUnit](doc/htmlunit.png)\u003c/td\u003e\u003ctd\u003e\n\n### HmtlUnit\n\n**Always headless**, java-based. No need to download anything.\n\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.useHtmlUnit()\u003c/code\u003e\u003c/summary\u003e\n\nConfigures HmtlUnit as the driver to be used. Provides additional configuration options that can be chained.\n\nCalling `$.driver().useHtmlUnit()` does not instantiate the driver right away, it merely configures it.\nThe driver will be instantiated when first used only (e.g. when `$.url(\"http://somepage\")` is called).\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoQuitDriver()\u003c/code\u003e\u003c/summary\u003e\n\nAutomatically quits the driver upon JVM shutdown.\n\nIf you don't use `.autoQuitDriver()`, you can quit the driver calling `$.quit()`.\n\nHaving `.autoQuitDriver()` on and still calling `$.quit()` makes no harm, so quit at will.\n\n**Note:** Since HtmlUnit is a java-based driver, it will quit upon JVM shutdown anyway. \n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withoutJavaScript()\u003c/code\u003e\u003c/summary\u003e\n\nRuns HtmlUnit with disabled JavaScript.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.emulatingChrome()\u003c/code\u003e\u003c/summary\u003e\n\nConfigures HtmlUnit to emulate Chrome.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.emulatingFirefox()\u003c/code\u003e\u003c/summary\u003e\n\nConfigures HtmlUnit to emulate Firefox.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.emulatingInternetExplorer()\u003c/code\u003e\u003c/summary\u003e\n\nConfigures HtmlUnit to emulate Internet Explorer.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withCapabilities(DesiredCapabilities)\u003c/code\u003e\u003c/summary\u003e\n\nConfigures the given `DesiredCapabilities` in the driver to be instantiated.\n\n\u003c/details\u003e\n\n\u003cbr\u003e\n\n```java\n// There are many possibilities to set up HtmlUnitDriver\n// HtmlUnit default (Chrome/JavaScript ON)\n$.driver().useHtmlUnit();\n// Want disabled JavaScript, just call .withoutJavaScript()\n$.driver().useHtmlUnit().withoutJavaScript();\n\n// HtmlUnit emulating Chrome\n$.driver().useHtmlUnit().emulatingChrome();\n$.driver().useHtmlUnit().emulatingChrome().withoutJavaScript();\n// HtmlUnit emulating Firefox\n$.driver().useHtmlUnit().emulatingFirefox(); // could disable JS here as well\n// And IE\n$.driver().useHtmlUnit().emulatingInternetExplorer11(); // JS is disableable as well\n$.driver().useHtmlUnit().emulatingInternetExplorer(); // will pick latest IE\n```\n\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\n\n![safari](doc/safari.png)\u003c/td\u003e\u003ctd\u003e\n\n### Safari\n\nseleniumQuery tests Safari as a **remote driver**.\n\n```java\n$.driver().useDriver(new SafariDriver());\n```\n\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\n\n![edge](doc/edge.png)\u003c/td\u003e\u003ctd\u003e\n\n### Edge\n\n**Automatic driver download** available.\n\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.useEdge()\u003c/code\u003e\u003c/summary\u003e\n\nConfigures Edge as the driver to be used. Provides additional configuration options that can be chained.\n\nCalling `$.driver().useEdge()` does not instantiate the driver right away, it merely configures it.\nThe driver will be instantiated when first used only (e.g. when `$.url(\"http://somepage\")` is called).\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoQuitDriver()\u003c/code\u003e\u003c/summary\u003e\n\nAutomatically quits the driver upon JVM shutdown.\n\nIf you don't use `.autoQuitDriver()`, you can quit the driver calling `$.quit()`.\n\nHaving `.autoQuitDriver()` on and still calling `$.quit()` makes no harm, so quit at will. \n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoDriverDownload()\u003c/code\u003e\u003c/summary\u003e\n\nseleniumQuery automatically downloads and configures the driver. The download is managed by [webdrivermanager](https://github.com/bonigarcia/webdrivermanager).\nAdditional options are available, pass a lambda to `.autoDriverDownload(\u003clabda\u003e)` to be able to configure:\n\n```java\n$.driver().useEdge().autoDriverDownload((BrowserManager configurer) -\u003e {\n    // se more options at https://github.com/bonigarcia/webdrivermanager#webdrivermanager-api\n    configurer.proxy(\"http://corpproxy:8182\");\n    configurer.proxyUser(\"myUser\");\n    configurer.proxyPass(\"myPass\")\n});\n```\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withOptions(EdgeOptions)\u003c/code\u003e\u003c/summary\u003e\n\nEnables additional configuration through a `EdgeOptions` instance.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withCapabilities(DesiredCapabilities)\u003c/code\u003e\u003c/summary\u003e\n\nConfigures the given `DesiredCapabilities` in the driver to be instantiated. Prefer `EdgeOptions` when possible.\n\n\u003c/details\u003e\n\n\u003cbr\u003e\n\n```java\n// Edge\n// we'll download the driver for you\n$.driver().useEdge().autoDriverDownload();\n// simplified setting of options\n$.driver()\n    .useEdge()\n    .withOptions(\u003can instance of EdgeOptions\u003e);\n```\n\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003ctr\u003e\n\u003ctd\u003e\n\n![internet explorer](doc/ie.png)\u003c/td\u003e\u003ctd\u003e\n\n### Internet Explorer\n\n**Automatic driver download** available. Additional info about configuration [can be found in our IE Driver wiki](https://github.com/seleniumQuery/seleniumQuery/wiki/seleniumQuery-and-IE-Driver).\n\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.useInternetExplorer()\u003c/code\u003e\u003c/summary\u003e\n\nConfigures Internet Explorer as the driver to be used. Provides additional configuration options that can be chained.\n\nCalling `$.driver().useInternetExplorer()` does not instantiate the driver right away, it merely configures it.\nThe driver will be instantiated when first used only (e.g. when `$.url(\"http://somepage\")` is called).\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoQuitDriver()\u003c/code\u003e\u003c/summary\u003e\n\nAutomatically quits the driver upon JVM shutdown.\n\nIf you don't use `.autoQuitDriver()`, you can quit the driver calling `$.quit()`.\n\nHaving `.autoQuitDriver()` on and still calling `$.quit()` makes no harm, so quit at will. \n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.autoDriverDownload()\u003c/code\u003e\u003c/summary\u003e\n\nseleniumQuery automatically downloads and configures the driver. The download is managed by [webdrivermanager](https://github.com/bonigarcia/webdrivermanager).\nAdditional options are available, pass a lambda to `.autoDriverDownload(\u003clabda\u003e)` to be able to configure:\n\n```java\n$.driver().useInternetExplorer().autoDriverDownload((BrowserManager configurer) -\u003e {\n    // se more options at https://github.com/bonigarcia/webdrivermanager#webdrivermanager-api\n    configurer.proxy(\"http://corpproxy:8182\");\n    configurer.proxyUser(\"myUser\");\n    configurer.proxyPass(\"myPass\")\n});\n```\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withPathToIEDriverServerExe(String)\u003c/code\u003e\u003c/summary\u003e\n\nIf you don't want seleniumQuery to automatically download the executable for you (using `.autoDriverDownload()`) you can\nspecify the location of `IEDriverServer.exe` yourself:\n\n```java\n$.driver().useInternetExplorer().withPathToIEDriverServerExe(\"C:\\\\IEDriverServer.exe\");\n```\n\nIf you use neither `.autoDriverDownload()` nor `.withPathToIEDriverServerExe()`, seleniumQuery will attempt to find `IEDriverServer.exe`\non your PATH or classpath. If it doesn't find it anywhere, an exception will be thrown.\n\n\u003c/details\u003e\n\u003cdetails\u003e\u003csummary\u003e\u003ccode\u003e.withCapabilities(DesiredCapabilities)\u003c/code\u003e\u003c/summary\u003e\n\nConfigures the given `DesiredCapabilities` in the driver to be instantiated.\n\n\u003c/details\u003e\n\n\u003cbr\u003e\n\n```java\n// InternetExplorerDriver\n// we'll download the driver for you\n$.driver().useInternetExplorer().autoDriverDownload();\n// or we search IEDriverServer.exe on your computer (path and classpash) for you\n$.driver().useInternetExplorer();\n// Or you set the path yourself\n$.driver().useInternetExplorer().withPathToIEDriverServerExe(\"C:\\\\IEDriverServer.exe\");\n```\n\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003c/table\u003e\n\n\u003cbr\u003e\n\n### Available `$(\"selector\").functions()`\n\nCheck the [javadocs for our `$().functions`](https://static.javadoc.io/io.github.seleniumquery/seleniumquery/0.19.1/index.html?io/github/seleniumquery/SeleniumQueryObject.html).\n\nMore info also in our [API wiki page](https://github.com/seleniumQuery/seleniumQuery/wiki/seleniumQuery-API).\n\n\u003cbr\u003e\n\n### Available `$.functions()`\n\nCheck the [javadocs for our `$.functions`](https://static.javadoc.io/io.github.seleniumquery/seleniumquery/0.19.1/index.html?io/github/seleniumquery/browser/BrowserFunctions.html).\n\nRead about our global functions in the [API wiki page](https://github.com/seleniumQuery/seleniumQuery/wiki/seleniumQuery-API).\n\n\u003cbr\u003e\n\n### Powerful selector system\n\nLet the tool do the hard work and find elements easily:\n\n- CSS3 Selectors - `$(\".myClass\")`, `$(\"#table tr:nth-child(3n+1)\")`\n- jQuery/Sizzle enhancements - `$(\".claz:eq(3)\")`, `$(\".claz:contains('My Text!')\")`\n- XPath - `$(\"//div/*/label/preceding::*\")`\n- and even some own seleniumQuery selectors: `$(\"#myOldDiv\").is(\":not(:present)\")`.\n\nYou pick your style. Whatever is more interesting at the moment. Mixing is OK:\n\n```java\n$(\"#tab tr:nth-child(3n+1)\").find(\"/img[@alt='calendar']/preceding::input\").val(\"2014-11-12\")\n```\nFind more about them in [seleniumQuery Selectors wiki page.](https://github.com/seleniumQuery/seleniumQuery/wiki/seleniumQuery-Selectors)\n\n\u003cbr\u003e\n\u003cbr\u003e\n\n## seleniumQuery still is Selenium - with \"just\" a jQuery interface\n\nSo there is a important aspect of it: Although our functions yield the same result as if you were using jQuery, remember we always execute them from the user perspective.\nIn other words, when you call:\n```java\n$(\":input[name='email']\").val(\"seleniumQuery@example.com\");\n```\n\nWe don't change  the `value` attribute directly like jQuery does. We actually do as a user would: We **clear** the input\nand **type, key by key**, the string provided as argument!\n\nAnd we go the *extra mile* whenever possible:\n- Our **`$().val()` even works on `contenteditable` elements AND `documentMode=on \u003ciframe\u003e`s**: They don't have `value`, but we type the text in them, again, key by key, as an user would;\n- If it is an `\u003cinput type=\"file\"\u003e` we select the file;\n- When the element is a `\u003cselect\u003e`, we choose the `\u003coption\u003e` by the value given (same as `$(\"selector\").as().select().selectByValue(\"123\")`).\n\n### Always from the user perspective\n\nOn the same tone, when selecting/checking `\u003coption\u003e`s or checkboxes or radios, try not to use `$().prop(\"selected\", true)` directly to them (which to work, of course, would need JS to be enabled on the driver).\nDo as an user would: call `.click()`! Or, better yet, use seleniumQuery's `.as().select()` functions: `$().as().select().selectByVisibleText(\"My Option\")` or `$().as().select().selectByValue(\"123\")`.\n\n\u003cbr\u003e\n\u003cbr\u003e\n\n# Using multiple browsers/drivers simultaneously\n\nTypically, the `$` is a static variable, thus every command you issue only affects the one same instance of WebDriver.\n\nBut... what if you want/need to use two WebDrivers at the same time?\n\nWe've got your back, see the [example](https://github.com/seleniumQuery/seleniumQuery-showcase/blob/master/src/main/java/browser/MultipleBrowsersExample.java#L27-L39):\n\n```java\npublic static void main(String[] args) {\n  String demoPage = \"https://cdn.rawgit.com/seleniumQuery/seleniumQuery-showcase/master/Agent.html\";\n\n  // using two drivers (chrome and firefox) at the same time\n  SeleniumQueryBrowser chrome = new SeleniumQueryBrowser();\n  chrome.$.driver().useHtmlUnit().emulatingChrome().autoQuitDriver();\n  chrome.$.url(demoPage);\n\n  SeleniumQueryBrowser firefox = new SeleniumQueryBrowser();\n  firefox.$.driver().useHtmlUnit().emulatingFirefox().autoQuitDriver();\n  firefox.$.url(demoPage);\n\n  chrome.$(\"#agent\").assertThat().text().contains(\"Chrome\");\n  firefox.$(\"#agent\").assertThat().text().contains(\"Firefox\");\n}\n```\n\n\u003cbr\u003e\n\n### Plugin System\n\nseleniumQuery supports plugins through the `.as(PLUGIN)` function, such as:\n\n```java\n$(\"div\").as(YOURPLUGIN).someMethodFromYourPlugin();\n```\n\nThere are some default plugins. To check them out, call `.as()` without arguments. Example:\n\n```java\n// the .select() plugin\n$(\"#citiesSelect\").as().select().selectByVisibleText(\"New York\");\n// picks an \u003coption\u003e in the \u003cselect\u003e based in the \u003coption\u003e's visible text\n```\n\nFor an example of how to create your own plugin, check the [seleniumQuery Plugin wiki page](https://github.com/seleniumQuery/seleniumQuery/wiki/seleniumQuery-Plugin-Support---.as()-function).\n\n\n\u003cbr\u003e\n\n### Alternate symbols\n\nIf the dollar symbol, `$`, gives you the yikes -- we know, it is used for internal class names --, it is important to notice that the `$` symbol in seleniumQuery is not a class name, but a `static` method (and field). Still, if you don't feel like using it, you can resort to `sQ()` or good ol' `jQuery()` and benefit from all the same goodies:\n\n```java\nimport static io.github.seleniumquery.SeleniumQuery.sQ;\nimport static io.github.seleniumquery.SeleniumQuery.jQuery;\n...\nString oldStreet = sQ(\"input.street\").val();\nsQ(\"input.street\").val(\"4th St!\");\n\nString oldStreetz = jQuery(\"input.street\").val();\njQuery(\"input.street\").val(\"5th St!\");\n```\n\n\u003cbr\u003e\n\n\n# More\n\nFind more on our [wiki](https://github.com/seleniumQuery/seleniumQuery/wiki).\n\n\u003cbr\u003e\n\n# Changelog/Roadmap\n\nSee [releases](https://github.com/seleniumQuery/seleniumQuery/releases).\n\n# Contributing or Requesting Features\n\nThe tool quite simple, so there's a lot of room for improvement. If you think something would be useful for you, it\n would probably be useful to us all, [tell us what you're thinking](https://github.com/seleniumQuery/seleniumQuery/issues/new)!\n\n","funding_links":[],"categories":["Resources"],"sub_categories":["Tools"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FseleniumQuery%2FseleniumQuery","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FseleniumQuery%2FseleniumQuery","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FseleniumQuery%2FseleniumQuery/lists"}