KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tonbeller > tbutils > testenv > Environment


1 package com.tonbeller.tbutils.testenv;
2
3 /**
4  * If the system properties <code>com.tonbeller.environment</code> is
5  * set to <code>test</code> then we are in an test environment and
6  * may behave different here and there.
7  *
8  * @author av
9  */

10 public class Environment {
11
12   private static boolean test = "test".equals(System.getProperty("com.tonbeller.environment"));
13
14   /**
15    * true if this VM runs in a test environment
16    *
17    * @return
18    */

19   public static boolean isTest() {
20     return test;
21   }
22 }
Popular Tags