示例#1
0
 def test_not_matches_barcode(self):
     # Begins with '72'
     usps = package.USPS20('72123456789123456787')
     assert usps.matches_barcode == False
示例#2
0
 def test_matches_barcode(self):
     usps = package.USPS20('71123456789123456787')
     assert usps.matches_barcode == True
示例#3
0
 def test_is_valid(self):
     usps = package.USPS20('71123456789123456787')
     assert usps.is_valid == True
示例#4
0
 def test_shipper(self):
     usps = package.USPS20('71123456789123456787')
     assert usps.shipper == 'USPS'
示例#5
0
 def test_tracking_number(self):
     usps = package.USPS20('71123456789123456787')
     assert usps.tracking_number == '71123456789123456787'
示例#6
0
 def test_barcode_spaces(self):
     usps = package.USPS20('7112 3456 7891 2345 6787')
     assert usps.barcode == '71123456789123456787'