def METHOD_NAME(self, upgrade_groups):
    """
    A database can be upgraded repeatedly over time with newer and newer
    schemas.
    """
    db = connect(":memory:")
    cursor = db.cursor()
    all_upgrades = dummy_upgrades(sum(upgrade_groups))
    some_upgrades = []
    for more_upgrades in upgrade_groups:
        some_upgrades = some_upgrades + all_upgrades[:more_upgrades]
        del all_upgrades[:more_upgrades]
        schema = Schema(some_upgrades)
        schema.run_upgrades(cursor)
    self.assertThat(
        schema.get_version(cursor),
        Equals(schema.version),
    )