Exemplo n.º 1
0
        void Qubinator_Should_Throw_Exception_If_Word_Has_Less_Than_3_Letters()
        {
            string wordNull = null;
            var    word     = "OI";

            Assert.Throws <ArgumentNullException>(() => Quber.To2DFull(wordNull));
            Assert.Throws <ArgumentException>(() => Quber.To2DFull(word));

            Assert.Throws <ArgumentNullException>(() => Quber.To2DSimple(wordNull));
            Assert.Throws <ArgumentException>(() => Quber.To2DSimple(word));

            Assert.Throws <ArgumentNullException>(() => Quber.To3D(wordNull));
            Assert.Throws <ArgumentException>(() => Quber.To3D(word));

            Assert.Throws <ArgumentNullException>(() => Quber.ToFullTextOffset(wordNull));
            Assert.Throws <ArgumentException>(() => Quber.ToFullTextOffset(word));
        }
Exemplo n.º 2
0
        public void Qubinator_Should_Generate_Correct_Full_Offseted_Text()
        {
            var result = Quber.ToFullTextOffset("BETELGEUSE");

            var expected =
                @"BETELGEUSE
ETELGEUSEB
TELGEUSEBE
ELGEUSEBET
LGEUSEBETE
GEUSEBETEL
EUSEBETELG
USEBETELGE
SEBETELGEU
EBETELGEUS
";

            Assert.Equal(expected, result);
        }