#4750 New test cases for Forward_zones
Closed: Fixed None Opened 9 years ago by spoore.

http://www.freeipa.org/page/V4/Forward_zones

ipa_dnsforwardzone_add

  • add forward zone with default policy and one forwarder
  • add forward zone policy=none and no forwarder
  • add forward zone policy=only and one forwarder
  • add forward zone policy=first and one forwarder
  • add forward zone policy=only and three forwarders
  • add forward zone policy=first and three forwarders
  • fail to add forward zone that already exists
  • fail to add forward zone that already exists as master
  • fail to add master zone with dnszone-add that already exists as forward
  • fail to add forward zone with empty name
  • fail to add forward zone with invalid name (unsupported char)
  • fail to add forward zone with no forwarder (default policy first)
  • fail to add forward zone policy=only and no forwarder
  • fail to add forward zone policy=first and no forwarder
  • fail to add forward zone policy=only and invalid forwarder ip
  • fail to add forward zone policy=first and invalid forwarder ip
  • fail to add forward zone policy=invalid

ipa_dnsforwardzone_mod

  • mod forward zone change one forwarder
  • mod forward zone change one forwarder when two exist
  • mod forward zone change two forwarders when two exist
  • mod forward zone policy=none add forwarders
  • mod forward zone change policy=none
  • mod forward zone change policy=only (policy none, FW exists)
  • mod forward zone change policy=first (policy none, FW exists)
  • mod forward zone change policy=none change forwarders empty
  • fail to mod non-existent forward zone
  • fail to mod forward zone without forwarders to --forward-policy=only
  • fail to mod forward zone without forwarders to --forward-policy=first
  • fail to mod forward zone policy=only change forwarders empty
  • fail to mod forward zone policy=first change forwarders empty
  • fail to mod forward zone policy=only change invalid forwarder ip
  • fail to mod forward zone policy=first change invalid forwarder ip
  • fail to mod forward zone change policy=invalid
  • fail to mod forward zone with dnszone-mod command

ipa_dnsforwardzone_show

  • show forward zone
  • fail to show non-existent forward zone
  • fail to show forward zone with ipa dnszone-show command

ipa_dnsforwardzone_find

  • find all forward zones
  • find all forward zones --pkey-only
  • find one forward zone with search criteria
  • find two forward zones with search criteria
  • find one forward zone with --name
  • find forward zone with --forward-policy=none
  • find forward zone with --forward-policy=only
  • find forward zone with --forward-policy=first
  • fail to find non-existent forward zone with search criteria
  • fail to find non-existent forward zone with --name
  • fail to find forward zone with --forward-policy=none
  • fail to find forward zone with --forward-policy=only
  • fail to find forward zone with --forward-policy=first
  • fail to find forward zone with dnszone-find command
  • fail to find master zone

ipa_dnsforwardzone_del

  • del forward zone
  • del forward zone with --continue
  • fail to del non-existent forward zone
  • fail to del non-existent forward zone with --continue
  • fail to del zone with dnszone-del command

ipa_dnsforwardzone_disable

  • disable forward zone
  • fail to disable non-existent forward zone
  • fail to disable already disabled forward zone?

ipa_dnsforwardzone_enable

  • enable forward zone
  • fail to enable non-existent forward zone
  • fail to enable already enabled forward zone?

ipa_dnsforwardzone_add-permission

  • add-permission for forward zone
  • fail to add-permission for non-existent forward zone
  • fail to add-permission for forward zone when already exists

ipa_dnsforwardzone_remove-permission

  • remove-permission for forward zone
  • fail to remove-permission for non-existent forward zone
  • fail to remove-permission for forward zone with no permission

ipa_dnsforwardzone_norecords

  • fail to dnsrecord-add for forward zone
  • fail to dnsrecord-mod for forward zone
  • fail to dnsrecord-find for forward zone

Already covered by positive test?:

fail to find forward zone with --forward-policy=none
fail to find forward zone with --forward-policy=only
fail to find forward zone with --forward-policy=first

Success is expected, same behavior is in 3.3.5:

fail to enable already enabled forward zone?
fail to disable already disabled forward zone?

Extra tests already covered by test suite:

Try to modify master zone %r using dnsforwardzone-mod (FAIL)
Try to delete master zone %r using dnsforwardzone-del (FAIL)
Try to retrieve master zone %r using dnsforwardzone-show (FAIL)
Try to add per-zone permission for forward zone %r using dnszone-add-permission (FAIL)
Try to remove per-zone permission for forward zone %r using dnszone-remove-permission (FAIL)
Try to add per-zone permission for master zone %r using dnsforwardzone-add-permission (FAIL)
Try to remove per-zone permission for master zone %r using dnsforwardzone-remove-permission (FAIL)
Try to remove per-zone permission for master zone %r using dnsforwardzone-remove-permission (FAIL)
Try to disable forward zone %r using dnszone-disable (FAIL)
Try to enable forward zone %r using dnszone-disable (FAIL)
Try to enable zone %r using dnsforwardzone-disable (FAIL)
Try to retrieve record %r in forward zone %r (FAIL)
Try to delete record %r in forward zone %r (FAIL)
Try to create forward zone %r with wildcard domain name (FAIL)
Modify forward policy from only to first (SUCCESS)
Modify forward policy from first to only (SUCCESS)

Replying to [comment:4 mbasti]:

Already covered by positive test?:
{{{
fail to find forward zone with --forward-policy=none
fail to find forward zone with --forward-policy=only
fail to find forward zone with --forward-policy=first
}}}

These I meant to cover the case where there is no zone matching the forward-policy for each case. So, what happens when you do a find with policy=none if only forward zone with policy=only?

Success is expected, same behavior is in 3.3.5:
{{{
fail to enable already enabled forward zone?
fail to disable already disabled forward zone?
}}}

Should these then be changed to be tests expected to pass then?

enable already enabled forward zone
disable already disabled forward zone

I will add these additional tests into patch then

master:

  • 92feba2 New test cases for Forward_zones
  • 6a0934f DNS tests: separate current forward zone tests

ipa-4-1:

  • 9f3b445 New test cases for Forward_zones
  • e5cd6f2 DNS tests: separate current forward zone tests

Metadata Update from @spoore:
- Issue assigned to mbasti
- Issue set to the milestone: FreeIPA 4.1.3

7 years ago

Login to comment on this ticket.

Metadata