Skip to content

Commit abc1f5b

Browse files
committed
Adding test
1 parent 2de26c2 commit abc1f5b

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tests/JWTTest.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,4 +228,10 @@ public function testMissingAlgorithm()
228228
$this->setExpectedException('DomainException');
229229
JWT::decode($msg, 'my_key');
230230
}
231+
232+
public function testAdditionalHeaders()
233+
{
234+
$msg = JWT::encode('abc', 'my_key', 'HS256', null, array('cty' => 'test-eit;v=1'));
235+
$this->assertEquals(JWT::decode($msg, 'my_key', array('HS256')), 'abc');
236+
}
231237
}

0 commit comments

Comments
 (0)