def create_empty_production_database():
    drop_database(name=DB_NAME)

    if get_db_engine() == 'postgresql_psycopg2':
        r = run_cmd('psql', 'postgres', '-c', DB_NAME % 'CREATE DATABASE %s')
        assert ('CREATE DATABASE' in force_text(r.std_out) or
                'already exists' in force_text(r.std_err))
        return

    if get_db_engine() == 'mysql':
        r = run_mysql('-e', 'CREATE DATABASE %s' % DB_NAME)
        assert (r.status_code == 0 or
                'database exists' in force_text(r.std_out) or
                'database exists' in force_text(r.std_err))
        return

    if get_db_engine() == 'sqlite3':
        if DB_NAME == ':memory:':
            raise AssertionError(
                'sqlite in-memory database must not be created!')
        open(DB_NAME, 'a').close()
        return

    raise AssertionError('%s cannot be tested properly' % get_db_engine())
dataset/ETHPy150Open pytest-dev/pytest-django/pytest_django_test/db_helpers.py/create_empty_production_database/swapped operands of `%`