Ashok Rawat
Ashok Rawat

Reputation: 11

Jenkins Spock Tests failing with java.lang.NoSuchMethodError: com.google.common.collect.Sets

JenkinsPipelineSpecification based tests fail with the error: java.lang.NoSuchMethodError: com.google.common.collect.Sets$SetView.iterator()Lcom/google/common/collect/UnmodifiableIterator;

Upvotes: 1

Views: 252

Answers (1)

Kathi
Kathi

Reputation: 282

I had a similar problem where the tests ran in Maven, but failed with the above error in IntelliJ IDEA. I fixed it by setting the project SDK and language level to 1.8 under File -> Project Structure -> Project -> Project SDK / Project language level. Maybe that helps someone out there.

Upvotes: 0

Related Questions