Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updates TestUtil.pm for unit tests #1340

Merged
merged 32 commits into from
May 22, 2024
Merged
Changes from 2 commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
6c19de9
Updates perform_testcase_testing() to support undelegated data plus t…
matsduf May 6, 2024
cbb0e5f
Adaption to updated TestUtil
matsduf May 6, 2024
8748e64
Corrects code errors
matsduf May 6, 2024
f4e6fdd
Corrects errors in the code
matsduf May 6, 2024
3dc5802
Corrects errors in one unit test
matsduf May 6, 2024
2454b53
Update t/TestUtil.pm
matsduf May 6, 2024
b029102
Editorial update from review comment
matsduf May 6, 2024
c19ead3
Adds some verification of "all tags" array
matsduf May 6, 2024
c6668a0
Clarification
matsduf May 6, 2024
d38dcf8
Adds documentation of the mechanism of undefined argument
matsduf May 6, 2024
c330a1d
Updates TestUtil.pm
matsduf May 7, 2024
9bc3e12
Adapts to updated TestUtils
matsduf May 7, 2024
dd0630d
Corrects NS name pattern
matsduf May 12, 2024
3987bd6
Adjusts error reporting
matsduf May 12, 2024
4263eba
Adapts to updated TestUtils
matsduf May 12, 2024
f46b5c6
Apply suggestions from code review
matsduf May 14, 2024
87dbe6c
Updates based on review comments
matsduf May 14, 2024
883c860
Update t/TestUtil.pm
matsduf May 15, 2024
5a114a6
Reorders the scenarios to be in same order as in the scenario specifi…
matsduf May 17, 2024
42c4cda
Adds five new scenarios
matsduf May 17, 2024
4936e86
Adds updated data
matsduf May 17, 2024
0367bb8
Reorders the scenarios to be in same order as in the scenario specifi…
matsduf May 18, 2024
c725b88
Adds two new scenarios
matsduf May 18, 2024
be9b4a7
Adds updated data
matsduf May 18, 2024
354471a
Editorial updates
matsduf May 21, 2024
ae82da2
Apply suggestions from code review
matsduf May 21, 2024
345c038
Editorial updates
matsduf May 21, 2024
ed80af8
Adds correct handling of empty tag arrays
matsduf May 21, 2024
f566274
Corrects and change logic: both arrays empty not permitted
matsduf May 22, 2024
d538a14
Apply suggestions from code review
matsduf May 22, 2024
7d11932
Editorial update
matsduf May 22, 2024
0bc6dcd
Apply suggestions from code review
matsduf May 22, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion t/TestUtil.pm
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,9 @@ undefined. If the mandatory message tag array is undefined, then it will be gene
all message tags not included in the forbidden message tag array. The same mechanism is used if the
forbidden message tag array is undefined.

The arrays of mandatory message tags and forbidden message tags, respectively, can be empty, but not
both. At least on of the arrays must be non-empty.
matsduf marked this conversation as resolved.
Show resolved Hide resolved

The name server expression has the format "name-server-name/IP" or only "name-server-name". The DS expression
has the format "keytag,algorithm,type,digest". Those two expressions have the same format as the data for
--ns and --ds options, respectively, for I<zonemaster-cli>.
Expand Down Expand Up @@ -143,7 +146,7 @@ sub perform_testcase_testing {

if ( defined( $mandatory_message_tags ) and defined( $forbidden_message_tags ) and
not scalar @{ $mandatory_message_tags } and not scalar @{ $forbidden_message_tags } ) {
croak "Scenario $scenario: Not both arrays of mandatory tags and array of forbidden tags, respectively, can be empty";
croak "Scenario $scenario: Not both arrays of mandatory message tags and forbidden message tags, respectively, can be empty";
}

if ( defined( $mandatory_message_tags ) and ref( $mandatory_message_tags ) ne 'ARRAY' ) {
Expand Down
Loading