From a9a56c86e22f1e157de4fe9a1180ad6cd48ce0c8 Mon Sep 17 00:00:00 2001 From: Aziem Chawdhary Date: Tue, 4 Jun 2024 21:25:30 +0000 Subject: [PATCH] Add more default values in test --- .../function/base/meta/AbstractTestReactivate.java | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/legend-pure-core/legend-pure-m3-core/src/test/java/org/finos/legend/pure/m3/tests/function/base/meta/AbstractTestReactivate.java b/legend-pure-core/legend-pure-m3-core/src/test/java/org/finos/legend/pure/m3/tests/function/base/meta/AbstractTestReactivate.java index 56b9ab7b3b..bede06a788 100644 --- a/legend-pure-core/legend-pure-m3-core/src/test/java/org/finos/legend/pure/m3/tests/function/base/meta/AbstractTestReactivate.java +++ b/legend-pure-core/legend-pure-m3-core/src/test/java/org/finos/legend/pure/m3/tests/function/base/meta/AbstractTestReactivate.java @@ -194,13 +194,23 @@ public void testReactivateNewDefaultValues() "Class test::A\n" + "{\n" + " a:Boolean[1] = true;\n" + + " i:Integer[1] = 10;\n" + + " enumProperty:EnumWithDefault[1] = test::EnumWithDefault.DefaultValue;\n" + + "}\n" + + "\n" + + "Enum test::EnumWithDefault\n" + + "{\n" + + " DefaultValue,\n" + + " AnotherValue\n" + "}\n" + "\n" + "function test::f():Boolean[1]\n" + "{\n" + " let l = {| ^test::A()};\n" + " let a = $l.expressionSequence->evaluateAndDeactivate()->toOne()->reactivate()->cast(@test::A)->toOne();\n" + - " assert($a.a, | '');\n" + + " assert($a.a, | 'Default value for property a set to wrong value');\n" + + " assertEquals($a.i, 10);\n" + + " assertEquals($a.enumProperty, test::EnumWithDefault.DefaultValue);\n" + "}\n"); execute("test::f():Boolean[1]"); }