更新时间:2021-08-13 16:08:53
封面
Title Page
Copyright and Credits
Selenium WebDriver 3 Practical Guide Second Edition
Packt Upsell
Why subscribe?
PacktPub.com
Contributors
About the author
About the reviewer
Packt is searching for authors like you
Preface
Who this book is for
What this book covers
To get the most out of this book
Installing Java
Installing Eclipse
Download the example code files
Download the color images
Conventions used
Get in touch
Reviews
Introducing WebDriver and WebElements
Selenium Testing Tools
Selenium WebDriver
Selenium Server
Selenium IDE
Differences between Selenium 2 and Selenium 3
Handling the browser
Having better APIs
Having developer support and advanced functionalities
Testing Mobile Apps with Appium
Setting up a project in Eclipse with Maven and TestNG using Java
WebElements
Locating WebElements using WebDriver
The findElement method
The findElements method
Inspecting Elements with Developer Tools
Inspecting pages and elements with Mozilla Firefox
Inspecting pages and elements in Google Chrome with Developer Tools
Using the By locating mechanism
The By.id() method
The By.name() method
The By.className() method
The By.linkText() method
The By.partialLinkText() method
The By.tagName() method
The By.xpath() method
The By.cssSelector() method
Interacting with WebElements
Getting element properties and attributes
The getAttribute() method
The getText() method
The getCssValue() method
The getLocation() method
The getSize() method
The getTagName() method
Performing actions on WebElements
The sendKeys() method
The clear() method
The submit() method
Checking the WebElement state
The isDisplayed() method
The isEnabled() method
The isSelected() method
Summary
Questions
Further information
Different Available WebDrivers
Firefox Driver
Using GeckoDriver
Using Headless Mode
Understanding the Firefox profile
Adding the extension to Firefox
Storing and retrieving a profile
Dealing with Firefox preferences
Setting preferences
Understanding frozen preferences
Chrome Driver
Using Mobile Emulation for testing mobile web applications
Adding ChromeExtensions
InternetExplorerDriver
Writing your first test script for the IE browser
Understanding IEDriver capabilities
Edge Driver
Writing your first test script for the Edge browser
Safari Driver
Writing your first test script for the Safari browser
Using Java 8 Features with Selenium
Introducing Java 8 Stream API
Stream.filter()
Stream.sort()
Stream.map()
Stream.collect()
Stream.min() and Stream.max()
Stream.count()