Psecio\Jwt\JwtTest::testSignWithPrivateKeyInvalidKey PHP Method

testSignWithPrivateKeyInvalidKey() public method

Test the signing with private key data (verify decode)
    public function testSignWithPrivateKeyInvalidKey()
    {
        $keyPath = 'file://' . __DIR__ . '/../../private.pem';
        $header = new \Psecio\Jwt\Header('test');
        $header->setAlgorithm('RS256');
        $jwt = new \Psecio\Jwt\Jwt($header);
        $jwt->audience('http://example.com');
        $result = $jwt->encode();
        $result = $jwt->decode($result);
        $this->assertEquals($result->aud, 'http://example.com');
    }