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