Maybe you like to get up-to-date with all your libraries. Me too.
If you're using rest-assured 4.0.0 in a project in conjunction with Spring Boot you'll get this exception in any test execution:
Java JDK 12
Spring Book 2.1.5.RELEASE
As indicated on https://github.com/rest-assured/rest-assured/wiki/GettingStarted#java-9 you may add a dependency rest-assured-all.
In my case, I'm using Maven (I don't know how to solve it for Gradle).
Simply add the following dependency without removing the rest-assured dependency:
That solves the problem (at least for me).
This error seems to appear only with JDK 12. I've tested with JDK 8 and the rest-assured-all was not necessary.