コード例 #1
0
        public void GivenMoodAnalyseClassName_ShouldReturnMoodAnalyseObject_UsingParameters()
        {
            object expected = new MoodAnalyse("HAPPY");
            object obj      = MoodAnalyseFactory.CreateMoodAnalysisUsingParameterizedConstructor("MoodAnalyzer.MoodAnalyse", "MoodAnalyse", "HAPPY");

            expected.Equals(obj);
        }
コード例 #2
0
        public void GivenMoodAnalyseClassName_ShouldReturnMoodAnalyseObject()
        {
            object expected = new MoodAnalyse();
            object obj      = MoodAnalyseFactory.CreateMoodAnalyse("MoodAnalyzerApp.MoodAnalyse", "MoodAnalyse");

            expected.Equals(obj);
        }
コード例 #3
0
        public void GivenMoodAnalyseClassName_ShouldReturnMoodAnalyseObject_UsingParameterizedConstructor()
        {
            object expected = new MoodAnalyse("HAPPY");
            object obj      = MoodAnalyseFactory.CreateMoodAnalyseUsingParameterizedConstructor("MoodAnalyserAppWithCoreLive1.MoodAnalyser", "MoodAnalyser", "SAD");

            expected.Equals(obj);
        }
コード例 #4
0
        public void GivenMoodAnalyseClassName_ShouldReturnMoodAnalyseObject()
        {
            string message  = null;
            object expected = new MoodAnalyse(message);
            object obj      = MoodAnalyseFactory.CreateMoodAnalyser("MoodeAnalyseAndExceptional.MoodAnalyse", "MoodAnalyse");

            expected.Equals(obj);
        }
コード例 #5
0
        public void TestMethodGivenMoodAnalyserClassNameShouldReturnMoodAnalyserObject()
        {
            string      className       = "MoodAnalyser.MoodAnalyse";
            string      constructorName = "MoodAnalyse";
            MoodAnalyse expected        = new MoodAnalyse();
            object      resultObj       = MoodAnalyserFactory.CreateMoodAnalyserObject(className, constructorName);

            expected.Equals(resultObj);
        }
コード例 #6
0
        public void GivenMoodAnalyser_className_Should_ReturnMoodAnalyserObject()
        {
            //Arrange
            object expexted = new MoodAnalyse();
            //Act
            object obj = MoodAnalyserFactorcs.CreateMoodAnalyse("MoodAnalyser.MoodAnalyse", "MoodAnalyse");

            //Assert
            expexted.Equals(obj);
        }
コード例 #7
0
        public void GivenModdAalyserClassName_ShouldReturnMoodAnalyserObject_UsingParametrizedConstructor()
        {
            //Arrange
            object excpected = new MoodAnalyse("HAPPY");
            //Act
            object obj = MoodAnalyserFactorcs.CreateMoodAnalyserObjectwithParaMeterizedConstructor("MoodAnalyser.MoodAnalyse", "MoodAnalyse", "HAPPY");

            //Assert
            excpected.Equals(obj);
        }
コード例 #8
0
        public void GivenMoodAnalyseShouldReturnMoodAnalyse()
        {
            object          expected    = new MoodAnalyse();
            ConstructorInfo constructor = MoodAnalyseFactory.GetConstructor("MoodAnalyse");

            string[] message   = { "I am in Sad Mood" };
            object   newObject = MoodAnalyseFactory.CreateMoodAnalyse(constructor, message);

            expected.Equals(newObject);
        }
コード例 #9
0
        public void TestMethodGivenMoodAnalyserClassNameShouldReturnMoodAnalyserObjectParameterisedConstructor()
        {
            //Arrange
            string      className       = "MoodAnalyser.MoodAnalyse";
            string      constructorName = "MoodAnalyse";
            MoodAnalyse expectedObj     = new MoodAnalyse("HAPPY");
            //Act
            object resultObj = MoodAnalyserFactory.CreateMoodAnalyserObjectParameterisedConstructor(className, constructorName, "HAPPY");

            //Assert
            expectedObj.Equals(resultObj);
        }