ddns_system.feature 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. Feature: DDNS System
  2. A number of BIND10-specific DDNS tests, that do not fall under the
  3. 'compliance' category; specific ACL checks, module checks, etc.
  4. Scenario: Module tests
  5. # This test runs the original example configuration, which has
  6. # a number of modules. It then removes all non-essential modules,
  7. # and checks whether they do disappear from the list of running
  8. # modules (note that it 'misuses' the help command for this,
  9. # there is a Boss command 'show_processes' but it's output is
  10. # currently less standardized than 'help')
  11. Given I have bind10 running with configuration ddns/noddns.config
  12. And wait for bind10 stderr message BIND10_STARTED_CC
  13. And wait for bind10 stderr message AUTH_SERVER_STARTED
  14. # Sanity check
  15. bind10 module DDNS should not be running
  16. # Test 1
  17. When I use DDNS to set the SOA serial to 1235
  18. # Note: test spec says refused here, system returns SERVFAIL
  19. #The DDNS response should be REFUSED
  20. The DDNS response should be SERVFAIL
  21. And the SOA serial for example.org should be 1234
  22. # Test 2
  23. When I configure bind10 to run DDNS
  24. And wait for new bind10 stderr message DDNS_RUNNING
  25. bind10 module DDNS should be running
  26. # Test 3
  27. When I use DDNS to set the SOA serial to 1236
  28. The DDNS response should be REFUSED
  29. And the SOA serial for example.org should be 1234
  30. # Test 4
  31. When I send bind10 the following commands
  32. """
  33. config add DDNS/zones
  34. config set DDNS/zones[0]/origin example.org
  35. config add DDNS/zones[0]/update_acl {"action": "ACCEPT", "from": "127.0.0.1"}
  36. config commit
  37. """
  38. # Test 5
  39. When I use DDNS to set the SOA serial to 1237
  40. The DDNS response should be SUCCESS
  41. And the SOA serial for example.org should be 1237
  42. # Test 6
  43. # XXX right after update, this fails?!
  44. When I send bind10 the command DDNS shutdown
  45. # Test 7
  46. And wait for new bind10 stderr message DDNS_RUNNING
  47. # Test 8
  48. When I use DDNS to set the SOA serial to 1238
  49. The DDNS response should be SUCCESS
  50. And the SOA serial for example.org should be 1238
  51. # Test 9
  52. When I send bind10 the command Auth shutdown
  53. # Test 10
  54. When I configure BIND10 to stop running DDNS
  55. And wait for new bind10 stderr message DDNS_STOPPED
  56. bind10 module DDNS should not be running
  57. # Test 11
  58. When I use DDNS to set the SOA serial to 1239
  59. # should this be REFUSED again?
  60. The DDNS response should be SERVFAIL
  61. And the SOA serial for example.org should be 1238