I want to check if a WordPress installation is working from a subdirectory.
Common methods to achieve this are listed here: https://codex.wordpress.org/Giving_WordPress_Its_Own_Directory
these usually involve changing an index file and requiring WordPress main file from there, perhaps changing rules in htaccess if using Apache - there's no setting up constants from what I can see
so, how would you detect reliably if WordPress is not running from a directory root?