Setting mock location permissions with Android

We have tests that rely on mocking location that we’ve successfully run locally after manually enabling developer options on the emulator device and setting mock location app to our app as well as adding permissions to an Android Manifest file inside our androidTest package folder. Are there any scripts or adb shell commands that make it possible to force enable mocking location on the android device inside circle ci before we run the tests.

Thank you