public function testAuthHeader() { $oauth = new OAuth2($this->container); $oauth->createService('A', 'B', 'C', 'D', 'E', array('f', 'g')); $oauth->setAccessToken('foobar', 'BeaRer'); $this->assertEquals('Authorization: Bearer foobar', $oauth->getAuthorizationHeader()); $oauth->setAccessToken('foobar', 'unknown'); $this->assertEquals('', $oauth->getAuthorizationHeader()); }