Exemplo n.º 1
0
        public void Capitals_NoCapitals_ReturnsEmptyArray()
        {
            //act
            var x = Kata.Capitals("abcdef");

            //assert
            Assert.IsEmpty(x);
        }
Exemplo n.º 2
0
        public void Capitals_WithCapitals_ReturnsCorrectArray()
        {
            //act
            var x = Kata.Capitals("CodEWaRs");

            //assert
            Assert.IsNotEmpty(x);
            Assert.That(x.Length, Is.EqualTo(4));
            Assert.That(x[0], Is.EqualTo(0));
            Assert.That(x[1], Is.EqualTo(3));
            Assert.That(x[2], Is.EqualTo(4));
            Assert.That(x[3], Is.EqualTo(6));
        }