-
Notifications
You must be signed in to change notification settings - Fork 539
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update docs for Grails 7 #929
Changes from 1 commit
79754e7
815e64e
0654cc3
7eb9d8d
8323074
099c45a
f3dcc13
264f1ee
7a6bd1f
e77a89f
46ebb39
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,4 +6,35 @@ Grails framework 7 updates Spring Boot to version 3.4. We recommend checking the | |
|
||
* https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-3.4-Release-Notes[Spring Boot 3.4] | ||
|
||
The minimum Java version required to run Grails 7 has been updated to Java 17. | ||
The minimum Java version required to run Grails 7 has been updated to Java 17. | ||
|
||
=== Ubiquitous Containerized Browser Testing with Geb | ||
|
||
The https://github.com/grails/geb[Grails Geb Plugin] has received a significant update, introducing test fixtures that enable ubiquitous containerized browser testing. | ||
|
||
This new approach is now the recommended way to write functional tests in Grails. However, the previous method using WebDriver binaries remains supported for backward compatibility. | ||
|
||
==== Key Features | ||
|
||
By extending your test classes with `ContainerGebSpec`, your tests will automatically leverage a containerized browser provided by https://www.testcontainers.org[Testcontainers]. This setup eliminates the need for managing browser versions and ensures consistent test environments. | ||
|
||
==== Requirements | ||
|
||
To use `ContainerGebSpec`, ensure that you have a compatible container runtime installed. Supported options include: | ||
|
||
- **Docker Desktop** | ||
- **OrbStack** (macOS only) | ||
- **Rancher Desktop** | ||
- **Podman Desktop** | ||
- **Colima** (macOS and Linux) | ||
|
||
==== How It Works | ||
|
||
Once a compatible container runtime is installed, no additional configuration is needed. Simply extend your test classes with `ContainerGebSpec` (instead of `GebSpec`), and the following will happen: | ||
|
||
1. A container will be started automatically when you run your integration tests. | ||
2. The container will be configured to launch a browser capable of accessing your application under test. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should it be mentioned, that There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It's an annotation to turn on reporting on ContainerGebSpec now. |
||
|
||
With this setup, you gain the benefits of containerized testing, such as isolation, reproducibility, and reduced setup complexity. | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
While we support it, isn't the erdi web driver plugin being abandoned? Should we clarify why we containerized this? The largest reason being that because the selenium & browser combination is a moving target, containers allow us to fix to a specific version and not break as browsers are updated over time.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. Web Driver Plugin limits you to max Gradle 8.6, which limits you to max Java 19. Plus the browser version matching the driver version is a large pain.