Example #1
0
        public static void WaterAnimals()
        {
            Console.WriteLine("");
            Console.WriteLine("Dino-Shark I am!");
            DinoShark dinoShark = new DinoShark();

            Console.WriteLine($"Scales: {dinoShark.Scales}.");
            Console.WriteLine($"Packs: {dinoShark.Packs}.");
            Console.WriteLine($"Location: {dinoShark.Location}.");
            Console.WriteLine($"Eyes: {dinoShark.Eyes}.");
            Console.WriteLine($"Feeding Cost:${dinoShark.FeedCost}.");
            Console.WriteLine($"Are they safe: {dinoShark.Safe}.");
            Console.WriteLine($"Eat: {dinoShark.Eat()}.");
            Console.WriteLine($"How many eggs laid a year: {dinoShark.EggsPerYear()}.");


            Console.WriteLine("");
            Console.WriteLine("Octopus I am!");
            Octopus octopus = new Octopus();

            Console.WriteLine($"Scales: {octopus.Scales}.");
            Console.WriteLine($"Packs: {octopus.Packs}.");
            Console.WriteLine($"Location: {octopus.Location}.");
            Console.WriteLine($"Eyes: {octopus.Eyes}.");
            Console.WriteLine($"Feeding Cost:${octopus.FeedCost}.");
            Console.WriteLine($"Are they safe: {octopus.Safe}.");
            Console.WriteLine($"Eat: {octopus.Eat()}.");
            Console.WriteLine($"How many eggs laid a year: {octopus.EggsPerYear()}.");
            Console.WriteLine($"Smarts: {octopus.Smart()}.");

            Console.WriteLine("");
            Console.WriteLine("Orca I am!");
            Orca orca = new Orca();

            Console.WriteLine("");
            Console.WriteLine($"Tails: {orca.Tail}.");
            Console.WriteLine($"Packs: {orca.Packs}.");
            Console.WriteLine($"Location: {orca.Location}.");
            Console.WriteLine($"Eyes: {orca.Eyes}.");
            Console.WriteLine($"Feeding Cost:${orca.FeedCost}.");
            Console.WriteLine($"Are they safe: {orca.Safe}.");
            Console.WriteLine($"Eat: {orca.Eat()}.");
            Console.WriteLine($"How many does it give birth per year: {orca.GiveBirth()}.");

            //Interface here as Well
            Console.WriteLine("Dino-Otter I am!");
            DinoOtter dinoOtter = new DinoOtter();

            Console.WriteLine($"Tails: {dinoOtter.Tail}.");
            Console.WriteLine($"Packs: {dinoOtter.Packs}.");
            Console.WriteLine($"Location: {dinoOtter.Location}.");
            Console.WriteLine($"Eyes: {dinoOtter.Eyes}.");
            Console.WriteLine($"Feeding Cost:${dinoOtter.FeedCost}.");
            Console.WriteLine($"Are they safe: {dinoOtter.Safe}.");
            Console.WriteLine($"Eat: {dinoOtter.Eat()}.");
            Console.WriteLine($"How many does it give birth per year: {dinoOtter.GiveBirth()}.");
            Console.WriteLine($"Interface => Fun Tricks: {dinoOtter.FunTricks}.");
            Console.WriteLine($"Interface => Loves Humans: {dinoOtter.Splash()}.");
            Console.ReadLine();
        }
Example #2
0
        public void OtterTest2()
        {
            DinoOtter testTwo = new DinoOtter();

            Assert.Equal(2_234.50m, testTwo.FeedCost);
        }
Example #3
0
        public void OtterTest1()
        {
            DinoOtter testOne = new DinoOtter();

            Assert.Equal("Watch me perfrom a trick back flip", testOne.Perform());
        }