ddns_system.feature 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102
  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 send a DDNS Update for example.org with the following commands:
  18. """
  19. update add example.org 3600 IN SOA ns1.example.org. admin.example.org. 1235 3600 1800 2419200 7200
  20. """
  21. # Note: test spec says refused here, system returns SERVFAIL
  22. #The DDNS response should be REFUSED
  23. The DDNS response should be SERVFAIL
  24. And the SOA serial for example.org should be 1234
  25. # Test 2
  26. When I send bind10 the following commands
  27. """
  28. config add Boss/components b10-ddns
  29. config set Boss/components/b10-ddns/kind dispensable
  30. config commit
  31. """
  32. And wait for new bind10 stderr message DDNS_RUNNING
  33. bind10 module DDNS should be running
  34. # Test 3
  35. When I send a DDNS Update for example.org with the following commands:
  36. """
  37. update add example.org 3600 IN SOA ns1.example.org. admin.example.org. 1236 3600 1800 2419200 7200
  38. """
  39. The DDNS response should be REFUSED
  40. And the SOA serial for example.org should be 1234
  41. # Test 4
  42. When I send bind10 the following commands
  43. """
  44. config add DDNS/zones
  45. config set DDNS/zones[0]/origin example.org
  46. config add DDNS/zones[0]/update_acl {"action": "ACCEPT", "from": "127.0.0.1"}
  47. config commit
  48. """
  49. # Test 5
  50. When I send a DDNS Update for example.org with the following commands:
  51. """
  52. update add example.org 3600 IN SOA ns1.example.org. admin.example.org. 1237 3600 1800 2419200 7200
  53. """
  54. The DDNS response should be SUCCESS
  55. And the SOA serial for example.org should be 1237
  56. # Test 6
  57. # XXX right after update, this fails?!
  58. #When I send bind10 the command DDNS shutdown
  59. # Test 7
  60. #And wait for new bind10 stderr message DDNS_RUNNING
  61. # Test 8
  62. When I send a DDNS Update for example.org with the following commands:
  63. """
  64. update add example.org 3600 IN SOA ns1.example.org. admin.example.org. 1238 3600 1800 2419200 7200
  65. """
  66. The DDNS response should be SUCCESS
  67. And the SOA serial for example.org should be 1238
  68. # Test 9
  69. # Test 10
  70. When I send bind10 the following commands
  71. """
  72. config remove Boss/components b10-ddns
  73. config commit
  74. """
  75. # XXX same problem of nonresponsive ddns?
  76. #And wait for new bind10 stderr message DDNS_STOPPED
  77. #bind10 module DDNS should not be running
  78. # Test 11
  79. When I send a DDNS Update for example.org with the following commands:
  80. """
  81. update add example.org 3600 IN SOA ns1.example.org. admin.example.org. 1239 3600 1800 2419200 7200
  82. """
  83. The DDNS response should be SERFVAIL
  84. And the SOA serial for example.org should be 1238