• 
      

    Remove the old execute_test_sql in preparation for a new one.

    Review Request #11241 — Created Oct. 23, 2020 and submitted

    Information

    Django Evolution
    master

    Reviewers

    execute_test_sql() was an older test function that set up a test
    database, set some model state, and then executed SQL, before tearing
    down that database.

    This wasn't as general as the name implied, and it was only called from
    a single place. An upcoming change will be altering some of the test SQL
    machinery, and in preparation, this function is being removed. Instead,
    ensure_test_db() now allows for setting an end model state (part of
    the former responsibility of execute_test_sql(), and the one call site
    now just calls ensure_test_db() and execute_transaction().

    Unit tests pass.

    Summary ID
    Remove the old execute_test_sql in preparation for a new one.
    `execute_test_sql()` was an older test function that set up a test database, set some model state, and then executed SQL, before tearing down that database. This wasn't as general as the name implied, and it was only called from a single place. An upcoming change will be altering some of the test SQL machinery, and in preparation, this function is being removed. Instead, `ensure_test_db()` now allows for setting an end model state (part of the former responsibility of `execute_test_sql()`, and the one call site now just calls `ensure_test_db()` and `execute_transaction()`.
    ae23e3d2405be245841f996c676ca6d2a03797f7
    david
    1. Ship It!
    2. 
        
    chipx86
    Review request changed
    Status:
    Completed
    Change Summary:
    Pushed to master (023524f)