public void Test_UpdateOrganizationBioInDB()
        {
            //Arrange
            Organization testOrganizationBio = new Organization("SaveTheMoistOwlet", "wwww.savethemoistowlet.com", "*****@*****.**", "Save the Planet from evil humans who want to burn things:(", "Large bio info");

            testOrganizationBio.Save();
            string updateOrganizationBio = "Saving the planet.";

            //Act
            testOrganizationBio.Update(updateOrganizationBio);
            string resultBio = testOrganizationBio.GetBio();

            //Assert
            Assert.Equal(updateOrganizationBio, resultBio);
        }
Ejemplo n.º 2
0
        // public decimal GetDonation()
        // {
        //   //return _donation;
        // }

        public override bool Equals(System.Object otherOrganization)
        {
            if (!(otherOrganization is Organization))
            {
                return(false);
            }
            else
            {
                Organization newOrganization  = (Organization)otherOrganization;
                bool         idEquality       = (this.GetId() == newOrganization.GetId());
                bool         nameEquality     = (this.GetName() == newOrganization.GetName());
                bool         websiteEquality  = (this.GetWebsite() == newOrganization.GetWebsite());
                bool         emailEquality    = (this.GetEmail() == newOrganization.GetEmail());
                bool         bioEquality      = (this.GetBio() == newOrganization.GetBio());
                bool         largeBioEquality = (this.GetLargeBio() == newOrganization.GetLargeBio());
                return(idEquality && nameEquality && websiteEquality && emailEquality && bioEquality && largeBioEquality);
            }
        }