Esempio n. 1
0
        public bool Idempotent_Rotations(Color c)
        {
            var rubik = Rubik.Init();

            rubik.RotateClockwise(c).RotateClockwise(c).RotateClockwise(c).RotateClockwise(c);

            return(rubik.Solved());
        }
Esempio n. 2
0
        public static Rubik Init()
        {
            var r = new Rubik();

            // Init Rubik here

            return(r);
        }
Esempio n. 3
0
        public bool Reverse_Rotations(List <Color> rotations)
        {
            var rubik = Rubik.Init();

            foreach (var r in rotations)
            {
                rubik.RotateClockwise(r);
            }

            var reverseRotations = new List <Color>(rotations);

            reverseRotations.Reverse();

            foreach (var rr in reverseRotations)
            {
                rubik.RotateCounterClockwise(rr);
            }

            return(rubik.Solved());
        }
Esempio n. 4
0
        public void Init()
        {
            var rubik = Rubik.Init();

            rubik.Should().Match <Rubik>(r => r.Solved());
        }