I want to be able to load a custom class from my pipeline script.
Specifically, I'm looking at having my pipeline script checkout fetch the Jenkinsfile and a number of .groovy files in the same directory (eg classA.groovy, classB.groovy)
I would expect to be able to have my pipeline script simply do a:
import classA
import classB
However, this results in an "Unable to resolve class" error.
I've tried the "pipeline-classpath-step-plugin", but it requires the main pipeline script to call its new step "AddToClassPath" and then load in an additional file which then can import.
Is there some other way to modify (or even to see) the classpath the script is running with?