https://github.com/sskorol/selenium-camp-17
Source code for SC17 talk: http://seleniumcamp.com/talk/how-java-8-can-simplify-test-automation
https://github.com/sskorol/selenium-camp-17
assertj java java-8 javamoney javaslang jsoup lombok pageobject qaa selenium-webdriver streamex test-automation testing testng
Last synced: 21 days ago
JSON representation
Source code for SC17 talk: http://seleniumcamp.com/talk/how-java-8-can-simplify-test-automation
- Host: GitHub
- URL: https://github.com/sskorol/selenium-camp-17
- Owner: sskorol
- License: apache-2.0
- Created: 2017-02-24T14:21:22.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2017-03-15T21:32:04.000Z (about 8 years ago)
- Last Synced: 2025-04-10T00:44:25.956Z (21 days ago)
- Topics: assertj, java, java-8, javamoney, javaslang, jsoup, lombok, pageobject, qaa, selenium-webdriver, streamex, test-automation, testing, testng
- Language: Java
- Homepage: http://seleniumcamp.com/talk/how-java-8-can-simplify-test-automation
- Size: 36.1 KB
- Stars: 15
- Watchers: 3
- Forks: 5
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README

# Selenium Camp 2017 - How does Java 8 exert hidden power on Test Automation?This project provides [talk's](http://seleniumcamp.com/talk/how-java-8-can-simplify-test-automation) demos' implementation.
Video recoding will be available in a month.
WARNING: it's not a QAA framework! It's just a set of useful code snippets, which were created in a **Java 7 vs Java 8** comparison format.
Here's a list of samples you may follow by watching talk's video recording:
#### Pattern Matching
- `core.driver.Java7WebDriverFactory`: switch vs if / else
- `core.driver.Java8WebDriverFactory`: [javaslang](http://www.javaslang.io) matchers
#### Lambdas / Functional Interfaces
- `core.wrappers.Java7BasePage`: explicit waits using Java 7
- `core.wrappers.Java8BasePage1stAttempt`: explicit waits using Java 8 (direct approach)
- `core.wrappers.Java8BasePage2stAttempt`: explicit waits using Java 8 (increasing readability via `core.wrappers.WaitCondition` - parametrized enum with [lombok](https://projectlombok.org))
#### Streams
- `resources/app/catalog.html`: target AUT (you should put it into some http server's space before tests execution)
- `model.Product`: common entity for storing product's info retrieved from AUT ([lombok](https://projectlombok.org) and [javamoney](https://javamoney.github.io))
- `pages.Java7ProductsPage`: Java 7 sample for getting a product with max discount according to retrieved AUT data
- `pages.Java8ProductsPage`: Java 8 sample for getting a product with max / min discount (or any other field) according to AUT data ([streamex](https://github.com/amaembo/streamex) and [lombok](https://projectlombok.org))
- `core.wrappers.BasePage`: abstract page for Java 8 sample ([javaslang](http://www.javaslang.io), [jsoup](https://jsoup.org), [javamoney](https://javamoney.github.io) and [streamex](https://github.com/amaembo/streamex))
- `testcases.SC17Java8WithoutDPTests`: test case without `DataProvider` usage for Java 8 sample ([javamoney](https://javamoney.github.io) and [lombok](https://projectlombok.org))
- `testcases.SC17Java8WithDPTests`: test case with `DataProvider` and `Tuples` usage for Java 8 sample ([javamoney](https://javamoney.github.io), [lombok](https://projectlombok.org) and [javaslang](http://www.javaslang.io))
#### Additional samples (out of talk's scope)
- `core.misc.PageFactory`: PageObjects factory for custom elements' types ([lombok](https://projectlombok.org), [streamex](https://github.com/amaembo/streamex) and [joor](https://github.com/jOOQ/jOOR))
- `utils.FileUtils`: custom waits ([awaitility](https://github.com/awaitility/awaitility))