예제 #1
0
 function tearDown()
 {
     Email::setMockMailer(null);
     if ($this->oldTemplates) {
         \Openclerk\Config::overwrite(array("emails_templates" => $this->oldTemplates));
     }
 }
 function __construct(Exchange $exchange)
 {
     $this->logger = new Logger("test");
     $this->exchange = $exchange;
     if ($this->isDebug()) {
         $this->logger->pushHandler(new BufferHandler(new ErrorLogHandler()));
     } else {
         $this->logger->pushHandler(new NullHandler());
     }
     Config::overwrite(array("get_contents_timeout" => 10));
 }
예제 #3
0
 function __construct()
 {
     parent::__construct(new \Exchange\Cryptsy());
     // public API key details for cryptsy API
     \Openclerk\Config::overwrite(array("exchange_cryptsy_key" => "21222550a305da84dc", "exchange_cryptsy_secret" => "openclerk/exchanges"));
 }
예제 #4
0
 function testExtraSlashes()
 {
     Config::overwrite(array("absolute_url" => "http://foo/"));
     $this->assertEquals("http://foo/bar", absolute_url("/bar"));
 }