The code has a runtime dependency which is not available in our development environment (and is available in test and prod). It's expensive to actually test for the dependency, and I want to test for the environment instead.
if (isDevEnvironment) {
// fake it
}
else {
// actually do it
}
Without using appSettings, what code/technique/test would you use to set isDevEnvironment
?
Example answers:
- check machine name (partial or full)
- check for running instance of Visual Studio
- check for environment variable
I'm hoping for a test I hadn't considered.