示例#1
0
        public void GetIsOfficial_ReturnsIsOfficial_Bool()
        {
            //Arrange
            string inputCountryCode = "TST";
            string inputLanguage    = "test-Language";
            bool   inputIsOfficial  = true;
            float  inputPercentage  = 4.0f;

            CountryLanguage testCountryLanguage = new CountryLanguage(inputCountryCode, inputLanguage, inputIsOfficial, inputPercentage);

            //Act
            bool resultIsOfficial = testCountryLanguage.GetIsOfficial();

            //Assert
            Assert.AreEqual(true, resultIsOfficial);
        }
示例#2
0
        public void SetIsOfficial_UpdatesIsOfficial_Void()
        {
            //Arrange
            string inputCountryCode = "TST";
            string inputLanguage    = "test-Language";
            bool   inputIsOfficial  = true;
            float  inputPercentage  = 4.0f;

            CountryLanguage testCountryLanguage = new CountryLanguage(inputCountryCode, inputLanguage, inputIsOfficial, inputPercentage);


            //Act
            bool inputIsOfficialUpdate = false;

            testCountryLanguage.SetIsOfficial(inputIsOfficialUpdate);
            bool resultIsOfficial = testCountryLanguage.GetIsOfficial();

            //Assert
            Assert.AreEqual(false, resultIsOfficial);
        }