/** * @test * * Ensure verifier can be set */ public function ensureVerifierCanBeSet() { $verifier = '12345abc'; $signature = $this->signature->setVerifier($verifier); $this->assertEquals($verifier, $this->signature->getVerifier()); $this->assertSame($signature, $this->signature); }
/** * Accessor method for setting a preconfigured signature which will set the other * properties from the data contained in the signature * * @param HmacSha1 $signature */ public function setSignature(HmacSha1 $signature) { $this->signature = $signature; $this->resourceUrl = $signature->getResourceURL(); $this->httpMethod = $signature->getHttpMethod(); $this->nonce = $signature->getNonce(); $this->timestamp = $signature->getTimestamp(); $this->verifier = $signature->getVerifier(); $this->postFields = $signature->getPostFields(); }