Beispiel #1
0
 public static function register(Botium $handler)
 {
     $app = new App($handler);
     $config = $handler->config();
     $duration = 0;
     if ($config && isset($config['every']) && $config['every'] > 0) {
         $duration = $config['every'];
     }
     if ($duration > 0) {
         sleep($duration);
     }
     $app->run();
 }
Beispiel #2
0
<?php

error_reporting(E_ALL);
ini_set('display_errors', 'On');
require __DIR__ . '/../vendor/autoload.php';
use Tests\Haixiu;
use Tests\Xieexiaozhan;
use Deloz\Botium\Botium;
$haixiu = new Haixiu(['baseUrl' => 'http://www.douban.com']);
$xieexiaozhan = new Xieexiaozhan(['baseUrl' => 'http://www.xieexiaozhan.com']);
Botium::register($haixiu);
Botium::register($xieexiaozhan);