@Test public void testIsConnectedFalse() { when(mMockMqttClient.isConnected()).thenReturn(false); assertThat(mTestIotCoreClient.isConnected()).isFalse(); verify(mMockMqttClient).isConnected(); }
public boolean isConnected() { return mMqttClient.isConnected(); }
IotCoreClient { public boolean isConnected() { return mMqttClient.isConnected(); } }
IotCoreClient { public boolean isConnected() { return mMqttClient.isConnected(); } private  IotCoreClient(
            @NonNull ConnectionParams connectionParams,
            @NonNull KeyPair keyPair,
            @NonNull MqttClient mqttClient,
            @NonNull Queue<TelemetryEvent> telemetryQueue,
            @Nullable Executor connectionCallbackExecutor,
            @Nullable ConnectionCallback connectionCallback,
            @Nullable Executor onConfigurationExecutor,
            @Nullable OnConfigurationListener onConfigurationListener,
            @Nullable Executor onCommandExecutor,
            @Nullable OnCommandListener onCommandListener); @VisibleForTesting  IotCoreClient(
            @NonNull ConnectionParams configuration,
            @NonNull MqttClient mqttClient,
            @NonNull JwtGenerator jwtGenerator,
            @NonNull AtomicBoolean runBackgroundThread,
            @NonNull AtomicReference<byte[]> unsentDeviceState,
            @NonNull Queue<TelemetryEvent> telemetryQueue,
            @Nullable Executor connectionCallbackExecutor,
            @Nullable ConnectionCallback connectionCallback,
            @Nullable Executor onConfigurationExecutor,
            @Nullable OnConfigurationListener onConfigurationListener,
            @Nullable Executor onCommandExecutor,
            @Nullable OnCommandListener onCommandListener,
            @NonNull Semaphore semaphore,
            @NonNull BoundedExponentialBackoff backoff,
            @NonNull AtomicBoolean clientConnectionState); }
IotCoreClient { public boolean isConnected() { return mMqttClient.isConnected(); } private  IotCoreClient(
            @NonNull ConnectionParams connectionParams,
            @NonNull KeyPair keyPair,
            @NonNull MqttClient mqttClient,
            @NonNull Queue<TelemetryEvent> telemetryQueue,
            @Nullable Executor connectionCallbackExecutor,
            @Nullable ConnectionCallback connectionCallback,
            @Nullable Executor onConfigurationExecutor,
            @Nullable OnConfigurationListener onConfigurationListener,
            @Nullable Executor onCommandExecutor,
            @Nullable OnCommandListener onCommandListener); @VisibleForTesting  IotCoreClient(
            @NonNull ConnectionParams configuration,
            @NonNull MqttClient mqttClient,
            @NonNull JwtGenerator jwtGenerator,
            @NonNull AtomicBoolean runBackgroundThread,
            @NonNull AtomicReference<byte[]> unsentDeviceState,
            @NonNull Queue<TelemetryEvent> telemetryQueue,
            @Nullable Executor connectionCallbackExecutor,
            @Nullable ConnectionCallback connectionCallback,
            @Nullable Executor onConfigurationExecutor,
            @Nullable OnConfigurationListener onConfigurationListener,
            @Nullable Executor onCommandExecutor,
            @Nullable OnCommandListener onCommandListener,
            @NonNull Semaphore semaphore,
            @NonNull BoundedExponentialBackoff backoff,
            @NonNull AtomicBoolean clientConnectionState); void connect(); boolean isConnected(); void disconnect(); boolean publishTelemetry(@NonNull TelemetryEvent event); void publishDeviceState(byte[] state); }
IotCoreClient { public boolean isConnected() { return mMqttClient.isConnected(); } private  IotCoreClient(
            @NonNull ConnectionParams connectionParams,
            @NonNull KeyPair keyPair,
            @NonNull MqttClient mqttClient,
            @NonNull Queue<TelemetryEvent> telemetryQueue,
            @Nullable Executor connectionCallbackExecutor,
            @Nullable ConnectionCallback connectionCallback,
            @Nullable Executor onConfigurationExecutor,
            @Nullable OnConfigurationListener onConfigurationListener,
            @Nullable Executor onCommandExecutor,
            @Nullable OnCommandListener onCommandListener); @VisibleForTesting  IotCoreClient(
            @NonNull ConnectionParams configuration,
            @NonNull MqttClient mqttClient,
            @NonNull JwtGenerator jwtGenerator,
            @NonNull AtomicBoolean runBackgroundThread,
            @NonNull AtomicReference<byte[]> unsentDeviceState,
            @NonNull Queue<TelemetryEvent> telemetryQueue,
            @Nullable Executor connectionCallbackExecutor,
            @Nullable ConnectionCallback connectionCallback,
            @Nullable Executor onConfigurationExecutor,
            @Nullable OnConfigurationListener onConfigurationListener,
            @Nullable Executor onCommandExecutor,
            @Nullable OnCommandListener onCommandListener,
            @NonNull Semaphore semaphore,
            @NonNull BoundedExponentialBackoff backoff,
            @NonNull AtomicBoolean clientConnectionState); void connect(); boolean isConnected(); void disconnect(); boolean publishTelemetry(@NonNull TelemetryEvent event); void publishDeviceState(byte[] state);  }