예제 #1
0
파일: test_sms.py 프로젝트: SciF0r/smspdu
 def test_pack(self):
     # example 3.16 from The Book, p74
     from smspdu.pdu import pack_date
     d = map(ord, pack_date('011223095342+04'))
     self.assertEquals(d, [16, 33, 50, 144, 53, 36, 64])
예제 #2
0
 def test_pack(self):
     # example 3.16 from The Book, p74
     from smspdu.pdu import pack_date
     d = list(b for b in pack_date('011223095342+04'))
     self.assertEqual(d, [16, 33, 50, 144, 53, 36, 64])
예제 #3
0
파일: test_sms.py 프로젝트: SciF0r/smspdu
 def _test(self, value):
     from smspdu.pdu import unpack_date, pack_date
     self.assertEqual(unpack_date(pack_date(value)), value)
예제 #4
0
 def _test(self, value):
     from smspdu.pdu import unpack_date, pack_date
     self.assertEqual(unpack_date(pack_date(value)), value)