Reworking the test for the CPU

This commit is contained in:
AnonymusRaccoon
2020-02-10 11:39:32 +01:00
parent fc94563b41
commit bd681c49a1
10 changed files with 103 additions and 61 deletions
+18
View File
@@ -0,0 +1,18 @@
//
// Created by anonymus-raccoon on 2/10/20.
//
#include <criterion/criterion.h>
#include <bitset>
#include "../tests.hpp"
#include "../../sources/SNES.hpp"
using namespace ComSquare;
Test(AddrMode, Immediate)
{
auto pair = Init();
pair.second.cpu->_registers.pc = 0x15;
cr_assert_eq(pair.second.cpu->_GetImmediateAddr(), 0x15);
cr_assert_eq(pair.second.cpu->_registers.pc, 0x16);
}