Category "groovy"

Unable to download Azure DevOps test result attachments using REST API in Groovy Unable to determine the current character

I need to download test result file attachments to a folder on my hard drive. When I run the call using talend it returns the file (png) image file in the body

what does No such DSL method 'readCSV' means in a jenkins pipeline?

I need to read a simple csv file and going through the documentation I found this readCSV method which comes with Jenkins, I have set a sample file named test.c

Jenkins groovy regex pattern search and match in commit message not working as expected

I'm working with this pipeline where running tests from a commit message should be an option. I'm a novice in groovy and regex, but I have managed to get matche

Groovy map, get, variable, Jenkins

I have a problem with mapping in Groovy. I would like to get a value based on a variable. def function(){ map = [ 'test1': '1234', 'test2'

Groovy-Eclipse Compilation Failed : Source level should be in '1.1'...'1.8','9'...'15' (or '5.0'..'15.0'): 17

I wanted to compile groovy along with java sources so I added groovy-eclipse-compiler to pom.xml but I got an error: Groovy-Eclipse: source level should be in

Problem when string date to Date format in groovy:

I'm trying to compare a String with a date in it with the current date, but when I try to parse the string to date format it always give me an error. the part

How can I fix "unsupported class file major version 60" in IntelliJ IDEA?

I have a Gradle project in Ubuntu. It's written in Java 14. I have the Java 14 JDK installed. When I build it from the command line, everything works, but no

setting micronaut configuration location

I have an existing groovy micronaut app I'm trying to change where it loads its config from. I don't understand what code to write so I can set the location of

Getting java.io.IOException: Server returned HTTP response code: 400 for URL: when using a url which return 400 status code

I am trying to perform a get request using Groovy using the below code: String url = "url of endpoint" def responseXml = new XmlSlurper().parse(url) If the endp

Jenkins Shared Library - Importing classes from the /src folder in /vars

I am trying to writing a Jenkins Shared Library for my CI process. I'd like to reference a class that is in the \src folder inside a global function defined in

Environment variable cannot be used in Jenkins JobDSL plugins

We use Jenkins JobDSL with ConfigurationAsCode for our CI setup. The job is checking if there is a difference in the Git repo and if there is : clone the repo,

Jenkins launches 2 builds when manually triggered

I've noticed a recent issue in both our instances of Jenkins. When launching a job manually, it launches twice. I've no idea what is causing it, but it's happen

Jenkins launches 2 builds when manually triggered

I've noticed a recent issue in both our instances of Jenkins. When launching a job manually, it launches twice. I've no idea what is causing it, but it's happen

Unable to find Groovy method when building Rhino with Intellij IDEA

While trying to build https://github.com/mozilla/rhino, I'm getting Unable to find method on org.codehaus.groovy.runtime.StringGroovyMethods. so the build fails

Assert mock call with argument assigned in where block in Spock

I have a method that among others generates an identifier, sends it to some external dependency and returns it. I want to have a unit test that tests if the sam

How to check if Jenkins build is waiting for input?

In Jenkins' Groovy, how can I detect that some other build is waiting for user input, as triggered by statements like input message: 'Retry?' ok: 'Restart'? I

Jenkins Shared Library src class - unable to resolve class

I am looking for some guidance on the design of a Jenkins Shared Library class. Using global vars as shared library is working fine but everytime I define a cla

Why this error? "No such property: Entry for class: java.util.Map"

I'm following an example from JENKINS-44085 issue very-bottom comments about creating a stage map almost to the T, but when I execute my code I get No such pro

Compile Groovy in VSCode

I've found the vscode-groovy extension that does the formatting and highlighting, but I'm really having trouble getting the compiler/debugger configured. I f

After updating cucumber-groovy I get "Access to 'PickleStepTestStep' exceeds its access rights"

After updating cucumber-groovy from version 4.7.1 to 6.1.2 I started getting an error Access to 'PickleStepTestStep' exceeds its access rights. In old version i