public void Poke_does_not_modify_StackPointer() { var uut = new ThreadStack(); uut.Poke(Variable.One); uut.StackPointer.Should().Be(0); }
public void Poke_modifies_top_value() { var uut = new ThreadStack(); uut.Poke(Variable.One); var result = uut.Peek(); result.Should().Be(Variable.One); }
public void Poke_with_param_modifies_the_item_offset_from_StackPointer() { var uut = new ThreadStack(); uut.Push(Variable.One); uut.Push(2); uut.Poke(-2, 15); var result = uut.Peek(-2); result.GetInteger().Should().Be(15); }