'Assert that the block ``parent_usage_key`` has ``child_usage_key`` listed
as one of its ``.children``.
Arguments:
parent_usage_key: The xblock to check as a parent.
child_usage_key: The xblock to check as a child.
draft (optional): If omitted, verify both published and draft branches.
If True, verify only the draft branch. If False, verify only the
published branch.'

def assertParentOf(self, parent_usage_key, child_usage_key, draft=None):

    if ((draft is None) or (not draft)):
        with self.store.branch_setting(ModuleStoreEnum.Branch.published_only):
            parent_block = self.store.get_item(parent_usage_key)
            self.assertIn(child_usage_key, parent_block.children)
    if ((draft is None) or draft):
        with self.store.branch_setting(ModuleStoreEnum.Branch.draft_preferred):
            parent_block = self.store.get_item(parent_usage_key)
            self.assertIn(child_usage_key, parent_block.children)
