browser.baseUrl
is the go-to method for retrieving the baseUrl.
I initially considered that there might be an alternative approach to accessing the command line baseUrl because my tests were failing on browserstack. It seemed like the baseUrl provided via the command line was being overlooked, leading to the utilization of the default value in the configuration. However, removing the default value from the configuration caused failures due to receiving a blank baseUrl.
The resolution to this issue remains unclear... as suddenly it started functioning correctly once more. This sudden shift could be attributed to caching (though the exact location is unknown) or potentially Jasmine2 (given that the problem was occurring within a BeforeAll block).
In any case, I wanted to provide an update and express gratitude to those who offered assistance!