grant = new AuthorizationCode(); } public function testDefault() : void { self::assertEquals('authorization_code', $this->grant->__toString()); self::assertEquals( [ 'code' => 'value', 'option' => '2', 'test' => 'value2', ], $this->grant->prepareRequestParamters( [ 'code' => 'value', ], [ 'option' => '2', 'test' => 'value2', ] ) ); } public function testMissingDefaultOption() : void { $this->expectException(\Exception::class); $this->grant->prepareRequestParamters( [ 'test' => 'value', ], [ 'option' => '2', 'test' => 'value2', ] ); } }