public void GivenMoodAnalyseClassNameShouldReturnMoodAnalyseObject()
        {
            object expected = new MoodAnalyserClass();
            object obj      = MoodAnalyserFactory.CreateMoodAnalyse("MoodAnalyserNameSpace.MoodAnalyserClass", "MoodAnalyserClass");

            expected.Equals(obj);
        }
示例#2
0
        public void Given_MoodAnalyserClassName_Should_ReturnMoodAnalyserObject()
        {
            object expected = new MoodAnalyserClass();
            object actual   = MoodAnalyserFactory.CreateMoodAnalyser("MoodAnalyser.MoodAnalyserClass", "MoodAnalyserClass");

            expected.Equals(actual);
        }
        public void GivenMoodAnalyseClassNameShouldReturnMoodAnalyseObjectUsingParameterisedConstructor()
        {
            object expected = new MoodAnalyserClass("Happy");
            object obj      = MoodAnalyserFactory.CreateMoodAnalyseUsingParameterizedConstructor("MoodAnalyserNameSpace.MoodAnalyserClass", "MoodAnalyserClass", "Happy");

            expected.Equals(obj);
        }
示例#4
0
        public void GivenMoodAnalyseClassName_ShouldReturnMoodAnalyseObject_UsingParameterizedConstructor()
        {
            object expected = new MoodAnalyserClass("HAPPY");
            object obj      = MoodAnalyserFactory.CreateMoodAnalyseUsingParameterizedConstructor("MoodAnalyserAppWithCore.MoodAnalyser", "MoodAnalyser", "SAD");

            expected.Equals(obj);
        }
示例#5
0
        public void GivenMoodAnalyseClassName_ShouldReturnMoodAnalyseObject()
        {
            string message  = null;
            object expected = new MoodAnalyserClass(message);
            object obj      = MoodAnalyserFactory.CreateMoodAnalyser("MoodAnalyserAppWithCore.MoodAnalyser", "MoodAnalyser");

            expected.Equals(obj);
        }
示例#6
0
        public void GivenMoodAnalyseClassName_ShouldReturnMoodAnalyseObject_UsingParameterizedConstructor()
        {
            string message  = "Happy";
            object expected = new MoodAnalyserClass(message);
            object actual   = MoodAnalyserFactory.CreateMoodAnalyseObjectUsingParamaterizedConstructor("MoodAnalyser.MoodAnalyserClass", "MoodAnalyserClass", "Happy");

            expected.Equals(actual);
        }
示例#7
0
        public void Given_MoodAnalyser_ClassName_Should_Return_MoodAnalyser_Object()
        {
            string            className       = "MoodAnalyser.MoodAnalyserClass";
            string            constructorName = "MoodAnalyserClass";
            MoodAnalyserClass expected        = new MoodAnalyserClass();
            object            resultObj       = MoodAnalyserFactory.CreateMoodAnalyserObject(className, constructorName);

            expected.Equals(resultObj);
        }
示例#8
0
        public void GivenMoodAnalyseClassName_ShouldReturnMoodAnalyseObject()
        {
            //string message = null;
            object expected = new MoodAnalyserClass();
            object actual   = MoodAnalyserFactory.CreateMoodAnalyse("MoodAnalyser.MoodAnalyserClass", "MoodAnalyserClass");

            expected.Equals(actual);
            //Assert.AreEqual(expected, actual) -> this can not be used, as we are not testing strings.or other data type, here it is object.
        }
示例#9
0
        public void GivenMoodAnalyserClassNameShouldReturnMoodAnalyserObject()
        {
            //Arrange
            var expected = new MoodAnalyserClass();
            //Act
            object result = MoodAnalyserFactory.CreateMoodAnalyserObject("MoodAnalyser.MoodAnalyserClass", "MoodAnalyserClass");

            //Assert
            expected.Equals(result);
        }
示例#10
0
        public void Given_MoodAnalyser_Class_Name_Should_Return_MoodAnalyser_Object_Using_Parametrized_Constructor()
        {
            //Arrange
            string            className       = "MoodAnalyser.MoodAnalyserClass";
            string            constructorName = "MoodAnalyserClass";
            MoodAnalyserClass expectedObj     = new MoodAnalyserClass("HAPPY");
            //Act
            object resultObj = MoodAnalyserFactory.CreateMoodAnalyserObjectUsingParametrisedConstructor(className, constructorName, "HAPPY");

            //Assert
            expectedObj.Equals(resultObj);
        }