예제 #1
0
 public void DieHard()
 {
     Title DieHard = new Movie(131);
     DieHard.name = "Die Hard";
     DieHard.rating = 4;
     string DieHardInfo;
     DieHardInfo = DieHard.ToString();
     Console.WriteLine(DieHardInfo);           
 }
예제 #2
0
 public void Heat()
 {
     Title Heat = new Movie(171);
     Heat.name = "Heat";
     Heat.rating = 3;
     string HeatInfo;
     HeatInfo = Heat.ToString();
     Console.WriteLine(HeatInfo);
 }
예제 #3
0
        public void MadMax()
        {
            Title MadMax= new Movie(88);
            MadMax.name = "Mad Max";
            MadMax.rating = 2;
            string MadMaxInfo;
            MadMaxInfo = MadMax.ToString();
            Console.WriteLine(MadMaxInfo);

        }
예제 #4
0
        public void KnockedUp()
        {
            Title KnockedUp= new Movie(129);
            KnockedUp.name = "Knocked Up";
            KnockedUp.rating = 2;
            string KnockedUpInfo;
            KnockedUpInfo = KnockedUp.ToString();
            Console.WriteLine(KnockedUpInfo);

        }
예제 #5
0
        public void RushHour()
        {
            Title RushHour = new Movie(97);
            RushHour.name = "Rush Hour";
            RushHour.rating = 2;
            string RushHourInfo;
            RushHourInfo = RushHour.ToString();
            Console.WriteLine(RushHourInfo);

        }
예제 #6
0
        public void MrMrsSmith()
        {
            Title MrMrsSmith= new Movie(123);
            MrMrsSmith.name = "Mr and Mrs Smith";
            MrMrsSmith.rating = 2;
            string MrMrsSmithInfo;
            MrMrsSmithInfo = MrMrsSmith.ToString();
            Console.WriteLine(MrMrsSmithInfo);

        }
예제 #7
0
        public void HotFuzz()
        {
            Title HotFuzz= new Movie(121);
            HotFuzz.name = "Hot Fuzz";
            HotFuzz.rating = 3;
            string HotFuzzInfo;
            HotFuzzInfo = HotFuzz.ToString();
            Console.WriteLine(HotFuzzInfo);

        }
예제 #8
0
        public void DieHardTest3()
        {
            Title DieHard = new Movie(131);
            Movie movie = new Movie(131);
            DieHard.name = "Die Hard";
            DieHard.rating = 4;
            string DieHardInfo;
            DieHardInfo = DieHard.ToString();
            Console.WriteLine(DieHardInfo);

            Assert.AreEqual(4, DieHard.rating);
        }
예제 #9
0
        public void DieHardTest2()
        {
            Title DieHard = new Movie(131);
            Movie movie = new Movie(131);
            DieHard.name = "Die Hard";
            DieHard.rating = 4;
            string DieHardInfo;
            DieHardInfo = DieHard.ToString();
            Console.WriteLine(DieHardInfo);

            Assert.AreEqual("Die Hard: 131 minutes long and 4 thumbs up!", DieHardInfo);
        }
예제 #10
0
        public void Zoolander()
        {
            Title Zoolander= new Movie(89);
            Zoolander.name = "Zoolander";
            Zoolander.rating = 2;
            string ZoolanderInfo;
            ZoolanderInfo = Zoolander.ToString();
            Console.WriteLine(ZoolanderInfo);

        }
예제 #11
0
        public void NotebookTest3()
        {
            Title Notebook = new Movie(121);
            Notebook.name = "The Notebook";
            Notebook.rating = 0;
            string NotebookInfo;
            NotebookInfo = Notebook.ToString();
            Console.WriteLine(NotebookInfo);

            Assert.ReferenceEquals(Notebook.name, Notebook.rating);
        }
예제 #12
0
        public void NotebookTest4()
        {
            Title Notebook = new Movie(121);
            Notebook.name = "The Notebook";
            Notebook.rating = 0;
            string NotebookInfo;
            NotebookInfo = Notebook.ToString();
            Console.WriteLine(NotebookInfo);

            Assert.IsNotInstanceOfType(typeof(Movie),typeof(Title));
        }
예제 #13
0
 public void Notebook()
 {
     Title Notebook= new Movie(121);
     Notebook.name = "The Notebook";
     Notebook.rating = 0;
     string NotebookInfo;
     NotebookInfo = Notebook.ToString();
     Console.WriteLine(NotebookInfo);
 }
예제 #14
0
        public void NotebookTest2()
        {
            Title Notebook = new Movie(121);
            Notebook.name = "The Notebook";
            Notebook.rating = 0;
            string NotebookInfo;
            NotebookInfo = Notebook.ToString();
            Console.WriteLine(NotebookInfo);

            Assert.AreEqual(NotebookInfo, Notebook.ToString());
        }
예제 #15
0
        public void SLP()
        {
            Title SLP = new Movie(122);
            SLP.name = "Silver Linings Playbook";
            SLP.rating = 1;
            string SLPInfo;
            SLPInfo = SLP.ToString();
            Console.WriteLine(SLPInfo);

        }
예제 #16
0
        static void Main(string[] args)
        {
            Genre comedy = new Genre();
            Genre romance = new Genre();
            TvShow tvShow = new TvShow();
            Episode episode = new Episode();
            
            List<string> Comedy = new List<string>();
            Comedy.Add("Anchorman");
            Comedy.Add("The Animal");

            List<string> Romance = new List<string>();
            Romance.Add("Trainwreck");
            Romance.Add("Titanic");

            
            Movie Anchorman = new Movie();
            Anchorman.name = "Anchorman";
            Anchorman.rating = 4;
            Anchorman.duration = 94;

            Movie TheAnimal = new Movie();
            TheAnimal.name = "The Animal";
            TheAnimal.rating = 2;
            TheAnimal.duration = 83;

            Movie Trainwreck = new Movie();
            Trainwreck.name = "Trainwreck";
            Trainwreck.rating = 3;
            Trainwreck.duration = 125;

            Movie Titanic = new Movie();
            Titanic.name = "Titanic";
            Titanic.rating = 5;
            Titanic.duration = 194;


            tvShow.name = "Walking Dead Season 1";
            tvShow.numberOfEpisodes = 6;
            List<string> Episodes = new List<string>();
            Episodes.Add("Days Gone By");
            Episodes.Add("Guts");
            Episodes.Add("Tell it to the frogs");
            Episodes.Add("Vatos");
            Episodes.Add("Wildfire");
            Episodes.Add("TS -19");
            Episode DaysGoneBy = new Episode();
            DaysGoneBy.rating = 5;
            
            Episode Guts = new Episode();
            Guts.rating = 5;
            Episode TellItToTheFrogs = new Episode();
            TellItToTheFrogs.rating = 4;
            Episode Vatos = new Episode();
            Vatos.rating = null;
            Episode Wildfire = new Episode();
            Wildfire.rating = 3;
            Episode TS19 = new Episode();
            TS19.rating = 4;
            






            

            


        }
예제 #17
0
        public void DieHardTest4()
        {
            Title DieHard = new Movie(131);
            Movie movie = new Movie(131);
            DieHard.name = "Die Hard";
            DieHard.rating = 4;
            string DieHardInfo;
            DieHardInfo = DieHard.ToString();
            Console.WriteLine(DieHardInfo);

            Assert.IsInstanceOfType(DieHard, typeof(Title));
        }
예제 #18
0
        public void Titanic()
        {
            Title Titanic = new Movie(194);
            Titanic.name = "Titanic";
            Titanic.rating = 1;
            string TitanicInfo;
            TitanicInfo = Titanic.ToString();
            Console.WriteLine(TitanicInfo);

        }
예제 #19
0
        public void DirtyDancing()
        {
            Title DirtyDancing= new Movie(100);
            DirtyDancing.name = "Dirty Dancing";
            DirtyDancing.rating = 4;
            string DirtyDancingInfo;
            DirtyDancingInfo = DirtyDancing.ToString();
            Console.WriteLine(DirtyDancingInfo);

        }
예제 #20
0
        public void PrincessBride()
        {
            Title PrincessBride= new Movie(98);
            PrincessBride.name = "The Princess Bride";
            PrincessBride.rating = 4;
            string PrincessBrideInfo;
            PrincessBrideInfo = PrincessBride.ToString();
            Console.WriteLine(PrincessBrideInfo);

        }
예제 #21
0
 public void EqualsTest5()
 {
     Movie movie1 = new Movie(GenreList.Comedy, "The Full Monty", 6.0, 80);
     Movie movie2 = new Movie(GenreList.Comedy, null, 6.0, 80);
     Assert.AreNotEqual(movie1, movie2);
 }