Ejemplo n.º 1
0
        public void Movi()
        {
            var stream = new CodeStream();

            stream.AsFluent()
            .Mov.RI(Register.A, 0);

            Assert.That(stream.First(), Is.EqualTo(new Instruction(OpCode.Mov).Destination(Register.A).Source(0)).Using(new InstructionComparer()));
        }
Ejemplo n.º 2
0
        public void Movi()
        {
            var stream = new CodeStream();

            stream.AsFluent()
                .Mov.RI(Register.A, 0);

            Assert.That(stream.First(), Is.EqualTo(new Instruction(OpCode.Mov).Destination(Register.A).Source(0)).Using(new InstructionComparer()));
        }
Ejemplo n.º 3
0
        public void Movr()
        {
            var stream = new CodeStream();

            stream.AsFluent()
                .Mov.RR(Register.A, Register.B);

            var expected = new Instruction(OpCode.Mov).Source(Register.B).Destination(Register.A);
            Assert.That(stream.First(), Is.EqualTo(expected).Using(new InstructionComparer()));
        }
Ejemplo n.º 4
0
        public void Movr()
        {
            var stream = new CodeStream();

            stream.AsFluent()
            .Mov.RR(Register.A, Register.B);

            var expected = new Instruction(OpCode.Mov).Source(Register.B).Destination(Register.A);

            Assert.That(stream.First(), Is.EqualTo(expected).Using(new InstructionComparer()));
        }