Expose IsTest Method (#1)

This commit is contained in:
Utsav Chokshi
2022-03-01 14:28:53 +05:30
committed by GitHub
parent 81f5d81b7b
commit 821f01cdde
3 changed files with 23 additions and 0 deletions

View File

@@ -237,4 +237,14 @@ public class Enry {
public static synchronized String getColor(String language) {
return toJavaString(nativeLib.GetColor(toGoString(language)));
}
/**
* Reports whether the given path is a test path or not.
*
* @param path of the file or directory
* @return whether it's test or not
*/
public static synchronized boolean isTest(String path) {
return toJavaBool(nativeLib.IsTest(toGoString(path)));
}
}