6 writes to Value
Microsoft.CodeAnalysis.CSharp.Scripting.UnitTests (6)
ScriptTests.cs (6)
422s1.GetVariable("x").Value = 2; 448Assert.Throws<ArgumentException>(() => state.GetVariable("x").Value = "str"); 449Assert.Throws<InvalidOperationException>(() => state.GetVariable("y").Value = "str"); 450Assert.Throws<InvalidOperationException>(() => state.GetVariable("z").Value = "str"); 451Assert.Throws<InvalidOperationException>(() => state.GetVariable("y").Value = 0); 452Assert.Throws<InvalidOperationException>(() => state.GetVariable("z").Value = 0);
9 references to Value
Microsoft.CodeAnalysis.CSharp.Scripting.UnitTests (8)
ScriptTests.cs (8)
404AssertEx.Equal(new object[] { '1', 2u, 3m, 5m, 20 }, state.Variables.Select(v => v.Value)); 407Assert.Equal(3m, state.GetVariable("a").Value); 408Assert.Equal(2u, state.GetVariable("b").Value); 409Assert.Equal(5m, state.GetVariable("x").Value); 410Assert.Equal(20, state.GetVariable("X").Value); 423Assert.Equal(2, s1.GetVariable("x").Value); 427Assert.Equal(1, s2.GetVariable("x").Value); 431Assert.Equal(2, s3.GetVariable("x").Value);
Microsoft.CodeAnalysis.Scripting (1)
ScriptVariable.cs (1)
74private string GetDebuggerDisplay() => $"{Name}: {Value ?? "<null>"}";