'Private helper method for assertAssetsEqual'

def _assertAssetsEqual(self, expected_course_key, expected_assets, actual_course_key, actual_assets):

    self.assertEqual(len(expected_assets), len(actual_assets))
    actual_assets_map = {asset['asset_key']: asset for asset in actual_assets}
    for expected_item in expected_assets:
        actual_item = actual_assets_map[expected_item['asset_key'].map_into_course(actual_course_key)]
        self.assertAssetEqual(expected_course_key, expected_item, actual_course_key, actual_item)
