Search Unity

Feature Request Run editor with custom script define(s)

Discussion in 'Testing & Automation' started by Johannski, Nov 9, 2021.

  1. Johannski

    Johannski

    Joined:
    Jan 25, 2014
    Posts:
    826
    I just stumbled upon a problem, that might be interesting to have from the test framework or (even better) from the unity command line arguments:
    Sometimes, tests or CI should behave differently then the normal editor. For that, it would be really nice to handle this with custom script defines. However, adding script defines in the CI for every method you want to execute seems a bit of an overkill. It would be awesome to pass them with command line arguments so that they are just added to the script defines defined in the project settings.
    something along the lines of
    Code (CSharp):
    1. unity.exe -custom-script-defines CUSTOM_DEFINE OTHER_DEFINE
    I hope this is the right place to ask for something like that :)