public function __construct(Client $eloqua, array $parameters, HookDispatcher $dispatcher)
 {
     $eloqua->authenticate($parameters['site'], $parameters['login'], $parameters['password'], $parameters['baseUrl']);
     $this->client = $eloqua;
     $this->parameters = $parameters;
     $this->dispatcher = $dispatcher;
 }
Exemplo n.º 2
0
 /**
  * @test
  * @expectedException InvalidArgumentException
  */
 public function shouldThrowExceptionWhenAuthenticatingWithEmptyCreds()
 {
     $httpClient = $this->getHttpClientMock(array('addListener'));
     $client = new Client($httpClient);
     $client->authenticate('', '', '');
 }