diff --git a/src/main/java/com/askimed/nf/test/lang/extensions/util/PathConverter.java b/src/main/java/com/askimed/nf/test/lang/extensions/util/PathConverter.java index 47d1d56f..4b254b00 100644 --- a/src/main/java/com/askimed/nf/test/lang/extensions/util/PathConverter.java +++ b/src/main/java/com/askimed/nf/test/lang/extensions/util/PathConverter.java @@ -26,6 +26,11 @@ public Object convert(Object value, String key) { if (!path.toFile().exists()) { throw new RuntimeException("Path " + path.toString() + " not found."); } + } else if (value instanceof File) { + path = ((File) value).toPath(); + if (!path.toFile().exists()) { + throw new RuntimeException("Path " + path.toString() + " not found."); + } } else { path = new File(value.toString()).toPath();