Changeset 1020 for branches/cname-collision
- Timestamp:
- 02/05/26 12:53:54 (5 days ago)
- File:
-
- 1 edited
-
branches/cname-collision/t/cname.t (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
branches/cname-collision/t/cname.t
r1016 r1020 433 433 }; # update to CNAME with no timestamp 434 434 435 subtest 'CNAME update - expires soon' => sub { 436 my @ltime = localtime(time + 86400 * 3); 437 $expirystamp = sprintf "%i-%i-%i %i:%i", $ltime[5] + 1900, ($ltime[4] + 1) % 12, $ltime[3], 15, $ltime[1]; 438 $newval = 'target.example.com'; 439 subtest 'collision with nonexpiring record' => sub { 440 $newname = 'expires1a.expiry3.test'; 441 ($code, $msg) = $dnsdb->updateRec('n', 'n', 89, 6, \$newname, \$rectype, \$newval, 900, undef, 't', $expirystamp); 442 ok($code eq 'FAIL', "updateRec() claimed failure"); 443 if ($code eq 'FAIL') { 444 ($rcount) = $dbh->selectrow_array("SELECT count(*) FROM records WHERE domain_id = 6 AND host = '$newname'"); 445 ok( $rcount == 1, " ... [$rcount] yep, hostname only occurs once" ); 446 like( $msg, qr/One or more non-CNAME records/, " ... returned matching error" ); 447 } 448 }; 449 }; 450 435 451 }; # record expiry/valid-after 436 452
Note:
See TracChangeset
for help on using the changeset viewer.
![[ DNS Administrator ]](/fx/dnsadmin-logo.png)