Unit tests are disabled by default with the migration to AGP 9 and enabling them adds a new androidHostTest / androidDeviceTest source set (details here). Enabling tests results in an error:
Cannot query the value of task ':x:generateMRandroidHostTest' property 'androidSourceSetName' because it has no value available.