diff --git a/src/main/java/com/google/api/gax/testing/GCloudEmulatorRunner.java b/src/main/java/com/google/api/gax/testing/GCloudEmulatorRunner.java index 5a2a76f9a46a..ce4e882af852 100644 --- a/src/main/java/com/google/api/gax/testing/GCloudEmulatorRunner.java +++ b/src/main/java/com/google/api/gax/testing/GCloudEmulatorRunner.java @@ -81,7 +81,7 @@ private boolean isGCloudInstalled() { private boolean isEmulatorUpdateToDate() throws IOException, InterruptedException { String currentVersion = installedEmulatorVersion(versionPrefix); - return currentVersion.compareTo(minVersion) >= 0; + return currentVersion != null && currentVersion.compareTo(minVersion) >= 0; } private String installedEmulatorVersion(String versionPrefix)