fix startup test failures from the driver

akkartik
Nov 17, 2023, 10:36 PM
POQ23S4HCIJJ22SXKQ5SWXE4F27UUHROKRJVONHV54IMRSBW2ZIQC

Dependencies

  • [2] 5WHW3IDO fix initialization errors using driver.love
  • [3] ARYMNK52 merge bugfix: show test failures
  • [4] TSV3KPBR tweak format of test failures
  • [5] ZKH2N6MN Merge text0
  • [6] 36Z442IV back to commit 8123959e52f without code editing
  • [*] 3QNOKBFM beginnings of a test harness
  • [*] BJ5X5O4A let's prevent the text cursor from ever getting on a drawing
  • [*] DTBFNHJD manual tests for the protocol with the driver

Change contents

  • replacement in app.lua at line 141
    [3.61][3.18:94]()
    error('There were test failures:\n\n'..table.concat(Test_errors, '\n'))
    [3.61]
    [3.131]
    Mode = 'error'
    Redo_initialization = true
    Error_message = 'There were test failures:\n\n'..table.concat(Test_errors, '\n')
    live.send_run_time_error_to_driver(Error_message)
  • edit in Manual_tests.md at line 124
    [2.2001]
    [2.2001]
    Driver can connect to app that contains test failures on startup.
  • edit in Manual_tests.md at line 126
    [2.2076]
    [10.1501]
    driver, define a new test with an invalid assertion:
    ```
    test_foo = function()
    check(nil, 'foo')
    end
    ```
    Hit F4. The test fails.
    Quit the client app and restart. App shows an error.
    Edit `test_foo` in the driver and remove the error:
    ```
    test_foo = function()
    end
    ```
    Hit F4. The error disappears from the app and driver.
    * clone this repo to a new client app, clear its save dir, run it, run the
    driver, define a new test with an invalid assertion:
    ```
    test_foo = function()
    check(nil, 'foo')
    end
    ```
    Hit F4.
    Quit the client app and restart. App shows an error.
    Hit F4 again in the driver (without fixing the error).
    The client app continues to show the error.
    * clone this repo to a new client app, clear its save dir, run it, run the