Im trying to create UnitTests for a private method : Im trying to create unitTests for the getoutofjail method but i cant workout a way of getting to it as it private and apart from testing there is no need for it to be public. I cant change the signature of the LandedonTile method as it inheriting a the abstract class Tile. 

As you probably worked out, it is for a game of Monopoly im trying to make as a mini project. Thanks in advanced for any help. 


    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;

    namespace Monolopy
     {
      public abstract class Tile
    {
        public abstract int Location { get;}
        public abstract void LandedOnTile(Player player);
    }
    }


    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;

    namespace Monolopy
    {
    public class JailTile : Tile
    {
        public override int Location { get; }
        Random dice = new Random();

        public JailTile()
        {
            Location = 3;
        }

        public override void LandedOnTile(Player player)
        {
            if (player.inJail)
            {
                GetOutOfJail(player);
            }
            else
            {
                Console.WriteLine(player.name + " is just visiting jail");
            }
        }

        private void GetOutOfJail(Player player)
        {
            int roll = dice.Next(1, 4);
            int turnsInJail = player.timeInJail;

            if (turnsInJail == 3)
            {
                player.inJail = false;
                Console.WriteLine(player.name + " has spent 3 turns in jail and is now out");
                player.timeInJail = 0;

            }
            else if (turnsInJail < 3 && roll > 2)
            {
                player.inJail = false;
                Console.WriteLine(player.name + " has rolled a 3 and it out of jail");
                player.timeInJail = 0;
            }
            else
            {
                Console.WriteLine(player.name + " has rolled a lower than a 3 and is in jail for another turn");
                player.timeInJail++;
            }
        }


    }
}
