println in “call” method of “vars/foo.groovy” works, but not in method in class
I'm iterating through building a Jenkins pipeline shared library, so my Jenkinsfile is a little cleaner. I'm using the following page for guidance: https://jenkins.io/doc/book/pipeline/shared-libraries/ . I first defined several methods in individual files, like " vars/methodName.groovy ", with a " call() " method in the code. This works ok, and I particularly note that " println " calls in these methods are seen in the Jenkins console output. I then decided I wanted to save some state between method calls, so I added a new file in " vars " named " uslutils.groovy " that begins like this