Exemplo n.º 1
0
        public void LoadMemoryFromRegister()
        {
            var process = ProgramLoader.LoadAssembly("MOV_LoadMemoryFromRegister.asm");

            while (!process.Exited)
            {
                process.Tick();
            }
            Assert.AreEqual(process.ProcessMemory[0], 12345);
        }
Exemplo n.º 2
0
        public void LoadRegisterFromRegisterTest()
        {
            var process = ProgramLoader.LoadAssembly("MOV_LoadRegisterFromRegister.asm");

            while (!process.Exited)
            {
                process.Tick();
            }
            Assert.AreEqual(process.Registers[(int)Register.AX], process.Registers[(int)Register.BX]);
        }
Exemplo n.º 3
0
        public void LoadRegisterFromMemoryTest()
        {
            var process = ProgramLoader.LoadAssembly("MOV_LoadRegisterFromMemory.asm");

            process.ProcessMemory[0] = 12345;
            while (!process.Exited)
            {
                process.Tick();
            }
            Assert.AreEqual(process.Registers[(int)Register.AX], 12345);
        }