jenkinsci / fortify-plugin

Fortify Jenkins plugin
https://plugins.jenkins.io/fortify
Other
23 stars 31 forks source link

Fixes tests and upgrades base jenkins to 2.387.3 #72

Closed froque closed 11 months ago

froque commented 11 months ago

Tests failed due to class jakarta.annotation.PostConstruct not being found.

This is because ssc-restapi-client depends on jakarta.annotation-api v1 overriding jenkins depending on jakarta.annotation-api v2.

jakarta.annotation-api v2 uses jakarta package and v1 uses the old javax package.

Adding an exclusion for jakarta.annotation:jakarta.annotation-api resolves this, but now fails with:

java.lang.IllegalStateException: Couldn't locate either of bouncy castle FIPS or non fips provider, available providers areSUN,SunRsaSign,SunEC,SunJSSE,SunJCE,SunJGSS,SunSASL,XMLDSig,SunPCSC,JdkLDAP,JdkSASL,SunPKCS11. at jenkins.bouncycastle.api.PEMEncodable.(PEMEncodable.java:96)

Bumping base jenkins to 2.387.3 and parent pom to 4.66 resolves this.

https://github.com/jenkinsci/jenkins/pull/6161 https://github.com/jenkinsci/bouncycastle-api-plugin/pull/46/

Testing done

### Submitter checklist
- [x] Make sure you are opening from a **topic/feature/bugfix branch** (right side) and not your main branch!
- [x] Ensure that the pull request title represents the desired changelog entry
- [x] Please describe what you did
- [ ] ~~Link to relevant issues in GitHub or Jira~~
- [x] Link to relevant pull requests, esp. upstream and downstream changes
- [x] Ensure you have provided tests - that demonstrates feature works or fixes the issue
akaryakina commented 11 months ago

@froque Thank you VERY MUCH! Examining all the exceptions occurring in tests is brilliant!

renyiwei-xinyi commented 5 months ago

nice! this issue helped me