'Verifies the asset of the given key has the same attributes in both given courses.'

def assertAssetsEqual(self, asset_son, course1_id, course2_id):

    content_store = contentstore()
    category = (asset_son.block_type if hasattr(asset_son, 'block_type') else asset_son['category'])
    filename = (asset_son.block_id if hasattr(asset_son, 'block_id') else asset_son['name'])
    course1_asset_attrs = content_store.get_attrs(course1_id.make_asset_key(category, filename))
    course2_asset_attrs = content_store.get_attrs(course2_id.make_asset_key(category, filename))
    self.assertEqual(len(course1_asset_attrs), len(course2_asset_attrs))
    for (key, value) in course1_asset_attrs.iteritems():
        if (key in ['_id', 'filename', 'uploadDate', 'content_son', 'thumbnail_location']):
            pass
        else:
            self.assertEqual(value, course2_asset_attrs[key])
