Example #1
0
        public void WhenTheRelativeAddressIsPositive_AndDoesNotCrossAPageBoundary_CalculatesTheCorrectAddress_AndIndicatesACycleCanBeSkipped()
        {
            _state.Registers.PC   = 0x0081;
            _state.Memory[0x0082] = 0x1F;

            var(address, canSkipCycle) = _relative.GetAddress(_state);

            address.Should().Be(0x00A2);
            canSkipCycle.Should().BeTrue();
        }