parameters: (self)
docstring: Test get_attributes
docstring_summary: Test get_attributes
docstring_tokens: Test get_attributes
function: def test_get_attributes(self):
          """Test get_attributes"""
          # empty packet
          self.assertEqual(self.doc.get_attributes(), 
              {}, 'Failed get_attributes')
          
          # single item packet
          self.doc.set('a', 1)
          self.assertEqual(self.doc.get_attributes(), 
              {'a': [1]}, 'Failed get_attributes')
          
          # multiple item packet
          self.doc.set('b', 2)
          self.assertEqual(self.doc.get_attributes(), {'a': [1], 'b': [2]}, 
              'Failed get_attributes')
          
          # packet with multivalued item
          self.doc.set('c', [3, 4])
          self.assertEqual(self.doc.get_attributes(), 
              {'a': [1],'b': [2],'c':[[3,4]]}, 'Failed get_attributes')
function_tokens: def test_get_attributes ( self ) : # empty packet self . assertEqual ( self . doc . get_attributes ( ) , { } , 'Failed get_attributes' ) # single item packet self . doc . set ( 'a' , 1 ) self . assertEqual ( self . doc . get_attributes ( ) , { 'a' : [ 1 ] } , 'Failed get_attributes' ) # multiple item packet self . doc . set ( 'b' , 2 ) self . assertEqual ( self . doc . get_attributes ( ) , { 'a' : [ 1 ] , 'b' : [ 2 ] } , 'Failed get_attributes' ) # packet with multivalued item self . doc . set ( 'c' , [ 3 , 4 ] ) self . assertEqual ( self . doc . get_attributes ( ) , { 'a' : [ 1 ] , 'b' : [ 2 ] , 'c' : [ [ 3 , 4 ] ] } , 'Failed get_attributes' )