groovy check if file exists code example
Example: groovy check if file exists
def filePath = "/tmp/file.json"
def file = new File(filePath)
assert file.exists() : "file not found"
def filePath = "/tmp/file.json"
def file = new File(filePath)
assert file.exists() : "file not found"