PHP Class Psecio\Jwt\HeaderTest

Inheritance: extends PHPUnit_Framework_TestCase
Show file Open project: psecio/jwt

Public Methods

Method Description
AlgorithmDataProvider ( ) Data provider for JWT algorithm hash to real hash string
setUp ( )
tearDown ( )
testConvertToString ( ) Test the conversion of the header to a string of JSON
testGetSetAlgorithmNoResolve ( ) Test that the same algorithm string is returned when no resolution is requested
testGetSetAlgorithmResolve ( string $algorithm, string $hashType ) Test that the right hash resolution is returned
testGetSetKey ( ) Test the getter/setter for the key value
testToArray ( ) Test the conversion of the header to an array

Method Details

AlgorithmDataProvider() public method

Data provider for JWT algorithm hash to real hash string

setUp() public method

public setUp ( )

tearDown() public method

public tearDown ( )

testConvertToString() public method

Test the conversion of the header to a string of JSON
public testConvertToString ( )

testGetSetAlgorithmNoResolve() public method

Test that the same algorithm string is returned when no resolution is requested

testGetSetAlgorithmResolve() public method

Test that the right hash resolution is returned
public testGetSetAlgorithmResolve ( string $algorithm, string $hashType )
$algorithm string Algorithm string (from JWT spec)
$hashType string Algorithm the type resolves to

testGetSetKey() public method

Test the getter/setter for the key value
public testGetSetKey ( )

testToArray() public method

Test the conversion of the header to an array
public testToArray ( )