diff --git a/src/connector/C#/src/test/FunctionTest/FetchLength.cs b/src/connector/C#/src/test/FunctionTest/FetchLength.cs index 928e1dfa92a723c52a2939bece2552ddeba7fd3f..b33377d49244ac74bb82dd8ae30b84b41336b88c 100644 --- a/src/connector/C#/src/test/FunctionTest/FetchLength.cs +++ b/src/connector/C#/src/test/FunctionTest/FetchLength.cs @@ -47,13 +47,24 @@ namespace Cases ResultSet actualResult = new ResultSet(resPtr); List actualData = actualResult.GetResultData(); List actualMeta = actualResult.GetResultMeta(); - expectData.Reverse(); + + // Make expected data and retrieved data in same order + expectData.Sort(); + actualData.Sort(); - Assert.Equal(expectData[0], actualData[0]); + // Assert meta data Assert.Equal(expectMeta[1].name, actualMeta[0].name); Assert.Equal(expectMeta[1].size, actualMeta[0].size); Assert.Equal(expectMeta[1].type, actualMeta[0].type); + // Assert retrieved data + for (int i = 0; i < actualData.Count; i++) + { + // Console.WriteLine($"expectData[{i}]:{expectData[i]},, actualData[{i}]:{actualData[i]}" ); + Assert.Equal(expectData[i].ToString(), actualData[i]); + } + } } -} +} +