title: Is there way for Swift code to detect if it's being run in a playground or not?
body: <p>To be able to test GameKit features, I'd like to be able to detect if the code is being run in a Playground, so that it can just skip the network calls. Is there a way to do this?</p>
  
  <p><strong>edit:</strong></p>
  
  <p>Forget about GameKit--that just muddies the issue. There are many different scenarios where this would be useful. It's really just a simple question about whether a specific function call exists or not: is there a method that returns <code>true</code> if the code is running in a Playground?</p>