public void Roundtrip_immediate_value_2() { var memory = new MemoryBank(); memory.SetValue(0, 99, ParameterMode.Immediate); Assert.AreEqual(99, memory.GetValue(0, ParameterMode.Immediate)); }
public void Roundtrip_positional_value_2() { var memory = new MemoryBank(); memory.SetValueImmediate(0, 1); memory.SetValue(0, 99, ParameterMode.Position); Assert.AreEqual(99, memory.GetValue(0, ParameterMode.Position)); }
public void GetValue_with_invalid_parametermode_should_throw() { var memory = new MemoryBank(); Assert.Throws <InvalidEnumArgumentException>(() => memory.GetValue(0, (ParameterMode)100)); }