Пример #1
0
 def test_bind(self):
     bound_id = ID.bind(identifier=self.one_id, object_type='i',
                        object_url='digital.library.gwu.edu/item/'+self.one_id,
                        description='Our first object!')
     self.assertEqual(bound_id.identifier, self.one_id)
     self.assertEqual(bound_id.requester_name, self.requester.name)
     self.assertEqual(bound_id.requester_ip, '127.0.0.1')
     self.assertEqual(bound_id.id_type, self.minter.minter_type)
     self.assertEqual(bound_id.object_type, 'i')
     self.assertEqual(bound_id.object_url, 'digital.library.gwu.edu/item/'+self.one_id)
     self.assertEqual(bound_id.description, 'Our first object!')
Пример #2
0
 def setUp(self):
     ids = ID.mint(requester_name='Gelman', minter_name='gwark', quantity=1)
     self.one_id = ids[0]
     bound_id = ID.bind(identifier=self.one_id, object_type='i',
                        object_url='digital.library.gwu.edu/item/'+self.one_id,
                        description='Our first object!')