For the
ci.jenkins.io Windows build, for a test I'm getting a failure of
14:12:17 java.lang.RuntimeException: java.io.IOException: java.lang.RuntimeException: Failed to serialize hudson.model.Project#buildWrappers for class hudson.model.FreeStyleProject 14:12:17 at hudson.util.PersistedList._onModified(PersistedList.java:214)
14:12:17 at hudson.util.PersistedList.add(PersistedList.java:80) 14:12:17 at io.jenkins.plugins.ksm.builder.KsmBuildWrapperTest.testBuilder(KsmBuildWrapperTest.java:210)
Which is basically me adding my BuildWrapper to a project's wrappers in a test.
project.getBuildWrappersList().add(buildWrapper);
Locally under Windows and Linux, I do not get this errors for the test. And even the
ci.jenkins.io Linux build doesn't have this problem.
I've tried adding implements Serializable to the class, and adding the problem classes to META-INF/hudson.remoting.ClassFilter as an attempt to get it working with no luck. Spitballing.
I normally don't do Java development so I'm kind of lost on why my tests work in some environments and not others.
Thanks,
John