def METHOD_NAME(self, getenv):
    # JAVA8_HOME, JAVA_HOME
    getenv.side_effect = [None, "/opt/jdks/jdk/1.8"]
    major, resolved_path = jvm.resolve_path(majors=8, sysprop_reader=self.path_based_prop_version_reader)
    assert major == 8
    assert resolved_path == "/opt/jdks/jdk/1.8"