mirror of
				https://github.com/elyby/oauth2-server.git
				synced 2025-05-31 14:12:07 +05:30 
			
		
		
		
	New test for getGrantType to test for exception
This commit is contained in:
		@@ -210,6 +210,16 @@ class Authorization_Server_test extends PHPUnit_Framework_TestCase
 | 
			
		||||
        $this->assertTrue($result instanceof OAuth2\Grant\GrantTypeInterface);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * @expectedException        OAuth2\Exception\InvalidGrantTypeException
 | 
			
		||||
     * @expectedExceptionCode    9
 | 
			
		||||
     */
 | 
			
		||||
    public function test_getGrantType_fail()
 | 
			
		||||
    {
 | 
			
		||||
        $a = $this->returnDefault();
 | 
			
		||||
        $a->getGrantType('blah');
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * @expectedException        OAuth2\Exception\ClientException
 | 
			
		||||
     * @expectedExceptionCode    0
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user