Skip to content

Commit

Permalink
Fix compilation failure issue
Browse files Browse the repository at this point in the history
Signed-off-by: zane-neo <[email protected]>
  • Loading branch information
zane-neo committed Sep 1, 2023
1 parent feeb927 commit 8dddbeb
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

package org.opensearch.neuralsearch.ml;

import static org.mockito.ArgumentMatchers.isA;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.times;

Expand Down Expand Up @@ -163,7 +162,7 @@ public void testInferenceSentences_whenNotConnectionException_thenNoRetry() {
}

public void test_inferenceSentencesWithMapResult_whenValidInput_thenSuccess() {
final Map<String, String> map = ImmutableMap.of("key", "value");
final Map<String, String> map = Map.of("key", "value");
final ActionListener<Map<String, ?>> resultListener = mock(ActionListener.class);
Mockito.doAnswer(invocation -> {
final ActionListener<MLOutput> actionListener = invocation.getArgument(2);
Expand Down Expand Up @@ -262,7 +261,9 @@ private ModelTensorOutput createModelTensorOutput(final Float[] output) {
output,
new long[] { 1, 2 },
MLResultDataType.FLOAT64,
ByteBuffer.wrap(new byte[12])
ByteBuffer.wrap(new byte[12]),
"someValue",
Map.of()
);
mlModelTensorList.add(tensor);
final ModelTensors modelTensors = new ModelTensors(mlModelTensorList);
Expand Down

0 comments on commit 8dddbeb

Please sign in to comment.