有没有办法知道程序是否在开发环境中运行?我正在使用 Flurry Analytics 并希望向它传递一个不同的应用程序 ID,因此数据不会在开发过程中被我的测试弄脏。
我想要的是这样的:
Boolean isDevEnv = .... (is this a test in the simulator or device,
OR is it a real user that downloaded the
app through the app store?)
if (isDevEnv)
[FlurryAnalytics startSession:@"firstAppId"];
else
[FlurryAnalytics startSession:@"secondAppId"];
需要明确的是,这不是我想要的,因为我使用真实设备和模拟器进行测试。