Beispiel #1
0
 public function testCredential()
 {
     $credential = new Credential("accessKeyId", "accessSecret");
     $this->assertEquals("accessKeyId", $credential->getAccessKeyId());
     $this->assertEquals("accessSecret", $credential->getAccessSecret());
     $this->assertNotNull($credential->getRefreshDate());
     $dateNow = gmdate('Y-m-d\\TH:i:s\\Z');
     $credential->setExpiredDate(1);
     $this->assertNotNull($credential->getExpiredDate());
     $this->assertTrue($credential->getExpiredDate() > $dateNow);
 }