Skip to content

Tag: groovy

How to trigger a task after build

I have the following code: If I write build.doLast(generateJavaApi), IntelliJ tells me the following: No candidates found for method call build.dolast. Why is that and how would you trigger generateJavaApi after build? (so that running gradle build would automatically also trigger the generation of the java a…

Can I add a delay to a call to a Stub method in Spock?

I’m using the Spock Framework to test some Java classes. One thing I need to do is add a delay to a Stub method that I’m calling, in order to simulate a long-running method. Is this possible? This looks possible using Mockito: Can I delay a stubbed method response with Mockito?. Is it possible usi…

Why can’t Nextflow handle this awk phrase?

Background: Using a csv as input, I want to combine the first two columns into a new one (separated by an underscore) and add that new column to the end of a new csv. Input: Desired output: The below awk phrase works from the command line: However, when placed within a nextflow script (below) it gives an erro…