From 39d5144791ac9954ad4e53c15e00de11f79626de Mon Sep 17 00:00:00 2001 From: Carlos Figueira Date: Thu, 25 Jan 2024 14:46:59 -0800 Subject: [PATCH] Update tests, add comments --- .../Microsoft.PowerFx.Core.Tests/FunctionTests.cs | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/tests/Microsoft.PowerFx.Core.Tests/FunctionTests.cs b/src/tests/Microsoft.PowerFx.Core.Tests/FunctionTests.cs index 7bf1297832..c2437dca68 100644 --- a/src/tests/Microsoft.PowerFx.Core.Tests/FunctionTests.cs +++ b/src/tests/Microsoft.PowerFx.Core.Tests/FunctionTests.cs @@ -299,11 +299,22 @@ public void TestScopeArguments() { for (int i = 0; i < 10; i++) { - Assert.Equal(i % 2 == 1, BuiltinFunctionsCore.AddColumns.ScopeInfo.AppliesToArgument(i)); + // AddColumns(, , [, , , ...] + Assert.Equal(i > 0 && i % 2 == 0, BuiltinFunctionsCore.AddColumns.ScopeInfo.AppliesToArgument(i)); + + // RenameColumns(
, , [, , , ...] Assert.Equal(i % 2 == 1, BuiltinFunctionsCore.RenameColumns.ScopeInfo.AppliesToArgument(i)); + + // ShowColumns(
, , , ...) Assert.Equal(i > 0, BuiltinFunctionsCore.ShowColumns.ScopeInfo.AppliesToArgument(i)); + + // DropColumns(
, , , ...) Assert.Equal(i > 0, BuiltinFunctionsCore.DropColumns.ScopeInfo.AppliesToArgument(i)); + + // Search(
, , , , ...) Assert.Equal(i > 1, BuiltinFunctionsCore.Search.ScopeInfo.AppliesToArgument(i)); + + // ShowColumns(
, , , , , ...) Assert.Equal(i % 2 == 1, BuiltinFunctionsCore.SortByColumns.ScopeInfo.AppliesToArgument(i)); } }