示例#1
0
 @Override
 public void stop() {
   if (!_openonce || _cyclecount % _maxsize == 0) {
     if (_openonce) ConfigHelper.getInstance().clearCache(this);
     getWrappedDriver().quit();
     isBrowserOpened = false;
   }
 }
 public static ConfigHelper getInstance() {
   try {
     ch.init();
   } catch (IOException e) {
     e.printStackTrace();
   } catch (Exception e) {
     e.printStackTrace();
   }
   return ch;
 }
示例#3
0
 public ZKSelenium(CommandProcessor processor, String openonce) {
   super(processor);
   this._openonce = ConfigHelper.isValidOpenOnce(openonce);
   if (_openonce) {
     try {
       _maxsize = Integer.parseInt(openonce);
       if (_maxsize < 0) _maxsize = Integer.MAX_VALUE;
     } catch (Exception e) {
     }
   }
 }