def test_landlord_details_address_lines_for_mailing_works(): ld = LandlordDetails() assert ld.address_lines_for_mailing == [] ld.address = "1 Cloud City\nBespin" assert ld.address_lines_for_mailing == ["1 Cloud City", "Bespin"] # Ensure it prefers granular details. ld.primary_line = "1 Cloud City" ld.city = "Bespin" ld.state = "OH" ld.zip_code = "43220" assert ld.address_lines_for_mailing == [ "1 Cloud City", "Bespin, OH 43220", ]
def test_landlord_details_address_lines_for_mailing_works(): ld = LandlordDetails() assert ld.address_lines_for_mailing == [] ld.address = '1 Cloud City\nBespin' assert ld.address_lines_for_mailing == ['1 Cloud City', 'Bespin']