'Verify that loading ``block_usage_key`` raises an ItemNotFoundError.
Arguments:
block_usage_key: The xblock to check.
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 assertBlockDoesntExist(self, block_usage_key, draft=None):

    if ((draft is None) or draft):
        with self.store.branch_setting(ModuleStoreEnum.Branch.draft_preferred):
            with self.assertRaises(ItemNotFoundError):
                self.store.get_item(block_usage_key)
    if ((draft is None) or (not draft)):
        with self.store.branch_setting(ModuleStoreEnum.Branch.published_only):
            with self.assertRaises(ItemNotFoundError):
                self.store.get_item(block_usage_key)
