def METHOD_NAME(session):
    """Assert the json format of share series."""
    identifier = 'CP1234567'
    business = factory_business(identifier)
    share_class = ShareClass(
        name='Share Class 1',
        priority=1,
        max_share_flag=True,
        max_shares=1000,
        par_value_flag=True,
        par_value=0.852,
        currency='CAD',
        special_rights_flag=False,
        business_id=business.id
    )
    share_series_1 = ShareSeries(
        name='Share Series 1',
        priority=1,
        max_share_flag=True,
        max_shares=500,
        special_rights_flag=False
    )
    share_class.series.append(share_series_1)
    share_class.save()
    share_class_json = {
        'id': share_class.id,
        'name': share_class.name,
        'priority': share_class.priority,
        'hasMaximumShares': share_class.max_share_flag,
        'maxNumberOfShares': share_class.max_shares,
        'hasParValue': share_class.par_value_flag,
        'parValue': share_class.par_value,
        'currency': share_class.currency,
        'hasRightsOrRestrictions': share_class.special_rights_flag,
        'series': [
            {
                'id': share_series_1.id,
                'name': share_series_1.name,
                'priority': share_series_1.priority,
                'hasMaximumShares': share_series_1.max_share_flag,
                'maxNumberOfShares': share_series_1.max_shares,
                'hasRightsOrRestrictions': share_series_1.special_rights_flag
            }
        ]
    }
    assert share_class_json == share_class.json