Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
samvaity committed Dec 6, 2019
1 parent 66ded80 commit fef3b0f
Showing 1 changed file with 3 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,7 @@
import com.azure.core.test.TestBase;
import com.azure.core.util.Configuration;
import com.azure.core.util.CoreUtils;
import com.azure.core.util.IterableStream;
import com.azure.core.util.logging.ClientLogger;
import com.azure.cs.textanalytics.implementation.models.DocumentLanguage;
import com.azure.cs.textanalytics.implementation.models.LanguageResult;
import com.azure.cs.textanalytics.models.DetectLanguageInput;
import com.azure.cs.textanalytics.models.DetectLanguageResult;
import com.azure.cs.textanalytics.models.DetectedLanguage;
Expand All @@ -47,7 +44,6 @@
import java.util.function.Consumer;
import java.util.function.Function;
import java.util.stream.Collectors;
import java.util.stream.StreamSupport;

import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertNotNull;
Expand Down Expand Up @@ -209,7 +205,7 @@ <T> void validateBatchResult(DocumentResultCollection<T> actualResult,
if (this.showStatistics) {
validateBatchStatistics(expectedResult.getStatistics(), actualResult.getStatistics());
}
validateDocumentsNew(expectedResult, actualResult, testApi);
validateDocuments(expectedResult, actualResult, testApi);

// TODO error model
// DocumentError error = new DocumentError().setId("4").setError("error");
Expand All @@ -225,8 +221,8 @@ <T> void validateBatchResult(DocumentResultCollection<T> actualResult,
* @param actualResult the actual result collection returned by the API.
* @param testApi the API to test.
*/
private <T> void validateDocumentsNew(DocumentResultCollection<T> expectedResult,
DocumentResultCollection<T> actualResult, String testApi) {
private <T> void validateDocuments(DocumentResultCollection<T> expectedResult,
DocumentResultCollection<T> actualResult, String testApi) {
switch (testApi) {
case "Language":
final List<DetectLanguageResult> expectedResultList = expectedResult.stream()
Expand Down

0 comments on commit fef3b0f

Please sign in to comment.