예제 #1
0
        public void Address_EqualsAddressDifferentAddress2_ReturnsFalse()
        {
            var address  = AddressBuilder.NewAddress;
            var address2 = AddressBuilder.WithAddress1("test address 2");

            Assert.NotEqual(address, address2);
        }
예제 #2
0
        static void Main(string[] args)
        {
            var builder = new AddressBuilder();

            var address = builder
                          .WithAddress1("123 Anywhere Blvd.")
                          .WithCity("Chicago")
                          .WithState("IL")
                          .WithZip("60652")
                          .Build();

            Console.WriteLine($@"
{address.Address1}
{address.City}, {address.State} {address.Zip}
			"            );
        }