public void GetAddressTest()
        {
            GoldMember newCustomer     = new GoldMember("0", "Johnny Appleseed", true, "00000000000", "22 Paper Street", System.DateTime.Now.AddYears(1));
            string     returnedAddress = newCustomer.GetAddress();

            Assert.AreEqual("22 Paper Street", returnedAddress);
        }
示例#2
0
        public void GoldMemberSavingLoadingTest()
        {
            GoldMember NewGoldMember = new GoldMember("0", "Johnny Appleseed", true, "00000000000", "22 Paper Street", System.DateTime.Now.AddYears(1));

            NewGoldMember.Save("TMGoldMember_Tests.txt");
            GoldMember GoldMemberLoad = GoldMember.LoadGoldMember("TMGoldMember_Tests.txt");
            string     Name1          = NewGoldMember.GetAddress();
            string     Name2          = GoldMemberLoad.GetAddress();

            Assert.AreEqual(Name1, Name2);
        }