From 731bef73df31dc47f7d497c88101f25789295339 Mon Sep 17 00:00:00 2001 From: Jan Date: Mon, 23 Dec 2019 23:54:19 +0100 Subject: [PATCH] ZoneCodeGenerator: Fix unit tests to do with evaluation array indices --- .../Parsing/CommandFile/Tests/TestCountTest.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/test/ZoneCodeGeneratorTests/Parsing/CommandFile/Tests/TestCountTest.cs b/test/ZoneCodeGeneratorTests/Parsing/CommandFile/Tests/TestCountTest.cs index ff53d48a..6da3bbaa 100644 --- a/test/ZoneCodeGeneratorTests/Parsing/CommandFile/Tests/TestCountTest.cs +++ b/test/ZoneCodeGeneratorTests/Parsing/CommandFile/Tests/TestCountTest.cs @@ -362,8 +362,10 @@ namespace ZoneCodeGeneratorTests.Parsing.CommandFile.Tests Assert.AreEqual(countEntry, dynamicOperand.ReferencedMemberChain[0].Member); Assert.AreEqual(2, dynamicOperand.ArrayIndices.Count); - Assert.AreEqual(7, dynamicOperand.ArrayIndices[0]); - Assert.AreEqual(4, dynamicOperand.ArrayIndices[1]); + Assert.IsTrue(dynamicOperand.ArrayIndices[0].IsStatic); + Assert.AreEqual(7, dynamicOperand.ArrayIndices[0].EvaluateNumeric()); + Assert.IsTrue(dynamicOperand.ArrayIndices[1].IsStatic); + Assert.AreEqual(4, dynamicOperand.ArrayIndices[1].EvaluateNumeric()); } [TestMethod]