MCPcopy Create free account
hub / github.com/aaPanel/BaoTa / test_jdk

Function test_jdk

mod/project/java/utils.py:79–86  ·  view source on GitHub ↗
(jdk_path: str)

Source from the content-addressed store, hash-verified

77 return jdk_path
78
79def test_jdk(jdk_path: str) -> bool:
80 java_bin = os.path.join(jdk_path, "bin/java")
81 if os.path.exists(java_bin):
82 out, err = public.ExecShell("{} -version 2>&1".format(java_bin))
83 # type: str, str
84 if out.lower().find("version") != -1:
85 return True
86 return False
87
88class TomCat:
89

Callers 1

Calls 5

ExecShellMethod · 0.80
joinMethod · 0.45
existsMethod · 0.45
formatMethod · 0.45
findMethod · 0.45

Tested by

no test coverage detected