4
0

loc-records.toml 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. # LOC record successes
  2. [[cmd]]
  3. name = "Running with ‘loc.example’ prints the correct LOC record"
  4. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC loc.example"
  5. stdout = { file = "outputs/loc.example.ansitxt" }
  6. stderr = { empty = true }
  7. status = 0
  8. tags = [ "loc", "madns" ]
  9. # LOC record successes (JSON)
  10. [[cmd]]
  11. name = "Running with ‘loc.example --json’ prints the correct LOC record structure"
  12. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC loc.example --json | jq"
  13. stdout = { file = "outputs/loc.example.json" }
  14. stderr = { empty = true }
  15. status = 0
  16. tags = [ "loc", "madns", "json" ]
  17. # LOC record out-of-range positions
  18. [[cmd]]
  19. name = "Running with ‘far-negative-longitude.loc.invalid’ displays a record with an out-of-range field"
  20. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC far-negative-longitude.loc.invalid"
  21. stdout = { file = "outputs/far-negative-longitude.loc.invalid.ansitxt" }
  22. stderr = { empty = true }
  23. status = 0
  24. tags = [ "loc", "madns" ]
  25. [[cmd]]
  26. name = "Running with ‘far-positive-longitude.loc.invalid’ displays a record with an out-of-range field"
  27. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC far-positive-longitude.loc.invalid"
  28. stdout = { file = "outputs/far-positive-longitude.loc.invalid.ansitxt" }
  29. stderr = { empty = true }
  30. status = 0
  31. tags = [ "loc", "madns" ]
  32. [[cmd]]
  33. name = "Running with ‘far-negative-latitude.loc.invalid’ displays a record with an out-of-range field"
  34. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC far-negative-latitude.loc.invalid"
  35. stdout = { file = "outputs/far-negative-latitude.loc.invalid.ansitxt" }
  36. stderr = { empty = true }
  37. status = 0
  38. tags = [ "loc", "madns" ]
  39. [[cmd]]
  40. name = "Running with ‘far-positive-latitude.loc.invalid’ displays a record with an out-of-range field"
  41. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC far-positive-latitude.loc.invalid"
  42. stdout = { file = "outputs/far-positive-latitude.loc.invalid.ansitxt" }
  43. stderr = { empty = true }
  44. status = 0
  45. tags = [ "loc", "madns" ]
  46. # LOC record out-of-range positions (JSON)
  47. [[cmd]]
  48. name = "Running with ‘far-negative-longitude.loc.invalid’ displays a record structure with an out-of-range field"
  49. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC far-negative-longitude.loc.invalid --json | jq"
  50. stdout = { file = "outputs/far-negative-longitude.loc.invalid.json" }
  51. stderr = { empty = true }
  52. status = 0
  53. tags = [ "loc", "madns", "json" ]
  54. [[cmd]]
  55. name = "Running with ‘far-positive-longitude.loc.invalid’ displays a record structure with an out-of-range field"
  56. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC far-positive-longitude.loc.invalid --json | jq"
  57. stdout = { file = "outputs/far-positive-longitude.loc.invalid.json" }
  58. stderr = { empty = true }
  59. status = 0
  60. tags = [ "loc", "madns", "json" ]
  61. [[cmd]]
  62. name = "Running with ‘far-negative-latitude.loc.invalid’ displays a record structure with an out-of-range field"
  63. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC far-negative-latitude.loc.invalid --json | jq"
  64. stdout = { file = "outputs/far-negative-latitude.loc.invalid.json" }
  65. stderr = { empty = true }
  66. status = 0
  67. tags = [ "loc", "madns", "json" ]
  68. [[cmd]]
  69. name = "Running with ‘far-positive-latitude.loc.invalid’ displays a record structure with an out-of-range field"
  70. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC far-positive-latitude.loc.invalid --json | jq"
  71. stdout = { file = "outputs/far-positive-latitude.loc.invalid.json" }
  72. stderr = { empty = true }
  73. status = 0
  74. tags = [ "loc", "madns", "json" ]
  75. # LOC record version 1
  76. [[cmd]]
  77. name = "Running with ‘v1-conform.loc.invalid’ displays a version error"
  78. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC v1-conform.loc.invalid"
  79. stdout = { empty = true }
  80. stderr = { string = "Error [protocol]: Malformed packet: record specifies version 1, expected up to 0" }
  81. status = 1
  82. tags = [ "loc", "madns" ]
  83. [[cmd]]
  84. name = "Running with ‘v1-nonconform.loc.invalid’ displays a version error"
  85. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC v1-nonconform.loc.invalid"
  86. stdout = { empty = true }
  87. stderr = { string = "Error [protocol]: Malformed packet: record specifies version 1, expected up to 0" }
  88. status = 1
  89. tags = [ "loc", "madns" ]
  90. [[cmd]]
  91. name = "Running with ‘v1-empty.loc.invalid’ displays a version error"
  92. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC v1-empty.loc.invalid"
  93. stdout = { empty = true }
  94. stderr = { string = "Error [protocol]: Malformed packet: record specifies version 1, expected up to 0" }
  95. status = 1
  96. tags = [ "loc", "madns" ]
  97. # LOC record invalid packets
  98. [[cmd]]
  99. name = "Running with ‘empty.loc.invalid’ displays a record length error"
  100. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC empty.loc.invalid"
  101. stdout = { empty = true }
  102. stderr = { string = "Error [protocol]: Malformed packet: insufficient data" }
  103. status = 1
  104. tags = [ "loc", "madns" ]
  105. [[cmd]]
  106. name = "Running with ‘incomplete.loc.invalid’ displays a record length error"
  107. shell = "dog --colour=always ${MADNS_ARGS:[email protected]:5301 --tcp} LOC incomplete.loc.invalid"
  108. stdout = { empty = true }
  109. stderr = { string = "Error [protocol]: Malformed packet: insufficient data" }
  110. status = 1
  111. tags = [ "loc", "madns" ]