def test_matches_barcode(self): ups = package.UPS('1Z999AA10123456784') assert ups.matches_barcode == True
def test_not_matches_barcode(self): # Begins with '1A' instead of '1Z' ups = package.UPS('1A999AA10123456784') assert ups.matches_barcode == False
def test_valid_checksum_zero_checksum(self): ups = package.UPS('1Z879E930346834440') assert ups.valid_checksum == True
def test_is_valid(self): ups = package.UPS('1Z999AA10123456784') assert ups.is_valid == True
def test_shipper(self): ups = package.UPS('1Z999AA10123456784') assert ups.shipper == 'UPS'
def test_tracking_number(self): ups = package.UPS('1Z999AA10123456784') assert ups.tracking_number == '1Z999AA10123456784'
def test_barcode_spaces(self): ups = package.UPS('1Z 999 AA 10123456784') assert ups.barcode == '1Z999AA10123456784'