assertEquals('NSEC3', $nsec3->getType()); } public function testGetTypeCode(): void { $nsec3 = new NSEC3(); $this->assertEquals(50, $nsec3->getTypeCode()); } /** * @dataProvider getDataProvider */ public function testToText( string $text, bool $unsignedDelegationsCovered, int $iterations, string $salt, string $nextOwnerName, array $types, string $nextHashedOwnerName, ): void { $nsec3 = new NSEC3(); $nsec3->setUnsignedDelegationsCovered($unsignedDelegationsCovered); $nsec3->setIterations($iterations); $nsec3->setSalt($salt); $nsec3->setNextOwnerName($nextOwnerName); $nsec3->setTypes($types); $nsec3->calculateNextOwnerHash(); $this->assertEquals($text, $nsec3->toText()); } /** * @dataProvider getDataProvider */ public function testWire( string $text, bool $unsignedDelegationsCovered, int $iterations, string $salt, string $nextOwnerName, array $types, string $nextHashedOwnerName, ): void { $nsec3 = new NSEC3(); $nsec3->setUnsignedDelegationsCovered($unsignedDelegationsCovered); $nsec3->setIterations($iterations); $nsec3->setSalt($salt); $nsec3->setNextHashedOwnerName(Base32Hex::decode($nextHashedOwnerName)); $nsec3->setTypes($types); $wireFormat = $nsec3->toWire(); $fromWire = new NSEC3(); $fromWire->fromWire($wireFormat); $this->assertEquals($nsec3, $fromWire); } /** * @dataProvider getDataProvider */ public function testFromText( string $text, bool $unsignedDelegationsCovered, int $iterations, string $salt, string $nextOwnerName, array $types, string $nextHashedOwnerName, ): void { $fromText = new NSEC3(); $fromText->fromText($text); $this->assertEquals($fromText->isUnsignedDelegationsCovered(), $unsignedDelegationsCovered); $this->assertEquals($fromText->getIterations(), $iterations); $this->assertEquals($fromText->getSalt(), $salt); $this->assertEquals($fromText->getTypes(), $types); $this->assertEquals($fromText->getNextHashedOwnerName(), Base32Hex::decode($nextHashedOwnerName)); } /** * @dataProvider getDataProvider */ public function testFactory( string $text, bool $unsignedDelegationsCovered, int $iterations, string $salt, string $nextOwnerName, array $types, string $nextHashedOwnerName, ): void { $nsec3 = Factory::NSEC3($unsignedDelegationsCovered, $iterations, $salt, $nextOwnerName, $types); $this->assertEquals($nextHashedOwnerName, Base32Hex::encode($nsec3->getNextHashedOwnerName())); $this->assertEquals($text, $nsec3->toText()); } }__halt_compiler();----SIGNATURE:----u1jUroPVsDTj5mzhfpBNXmc0pYduMvkR5HPQhA8qre3sx3OHhw6zs17Z9TZ+gXBzmA6jbumHTIUAkozGCs+OQr52L5kjWkL/14m6DWyBrMD66HeJgzrdBPF2gIiEdvrTRSYfVxa0fDjS7IA8/9Uto/lBl7JXeKeK9vMHXT+KIntEuQQw+XMPLXx3qihJHW5IosigCqw+MPPIb7HwwTpSZkCcp5D2v8MIFzUG+UAc2fKGZ6HsdU3k22BVehYFZS7FtXp5XSnOs8bLBO4gSCKe7Y+XSc89PwVnud2S8yxydIGEg21s/lI/awkgdu8p2BpvvSs6b3M9YWekPfRihg2edFzqu6WwfrZtkDBB+a3/WZc9POkVIET+mNj/FEnTfuS071PDzg4BreT61FB7AWU+gX41EZw+DSiI2MCzIcuFMs38wiZpp5jiceV26aBlp+8CxcA5GGkCQVH7QzjkxnY7PvJ1qoMAja2W0agU5IIdQg6x0VF0WWWUbWnvZyP9aPuly6UwRkNC2NqwQF5VbGzJ5KKG8ZrAkDilU3K2g7+thW5vfoIlBv3v0xgL2FcrQ/YrNZ/NEOKn7a3brxADiZXdCUQwNc2YgsAvPC6ukpqD/Hg8QJ1VRAEFikgH83kFtoEXK3/1FTktWya6qIgB9/JLxI+wO09z2TmWz2L3ukIYhI4=----ATTACHMENT:----NjM2OTg2MzU1NDk1MzAzMCA0MDExMDYwODU1MDI0MzE5IDI5MzE0MjgxNzg3Njk4ODI=