test_finish 0
}
-# This test verifies that the binary is reporting its version properly.
-version_test() {
- test_name=${1} # Test name
-
- # Log the start of the test and print test name.
- test_start "${test_suite}-${test_name}"
-
- REPORTED_VERSION=$(${shell_bin_path}/${shell_bin} -v)
-
- if test "${REPORTED_VERSION}" = "${EXPECTED_VERSION}"; then
- test_finish 0
- else
- echo "ERROR:" \
- "Expected version ${EXPECTED_VERSION}, got ${REPORTED_VERSION}"
- test_finish 1
- fi
-}
-
-version_test "shell.version"
shell_command_test "shell.list-commands" "list-commands" \
"[ { \"arguments\": [ \"build-report\", \"config-get\", \"config-hash-get\", \"config-reload\", \"config-set\", \"config-test\", \"config-write\", \"list-commands\", \"shutdown\", \"status-get\", \"version-get\" ], \"result\": 0 } ]" ""
shell_command_test "shell.bogus" "give-me-a-beer" \
test_finish 0
}
-# This test verifies that the binary is reporting its version properly.
-version_test() {
- test_name=${1} # Test name
-
- # Log the start of the test and print test name.
- test_start "${test_suite}-${test_name}"
-
- REPORTED_VERSION=$(${shell_bin_path}/${shell_bin} -v)
-
- if test "${REPORTED_VERSION}" = "${EXPECTED_VERSION}"; then
- test_finish 0
- else
- echo "ERROR:" \
- "Expected version ${EXPECTED_VERSION}, got ${REPORTED_VERSION}"
- test_finish 1
- fi
-}
-
-version_test "shell.version"
shell_command_test "shell.list-commands" "list-commands" \
"[ { \"arguments\": [ \"build-report\", \"config-get\", \"config-hash-get\", \"config-reload\", \"config-set\", \"config-test\", \"config-write\", \"list-commands\", \"shutdown\", \"statistic-get\", \"statistic-get-all\", \"statistic-reset\", \"statistic-reset-all\", \"status-get\", \"version-get\" ], \"result\": 0 } ]" ""
shell_command_test "shell.bogus" "give-me-a-beer" \
test_finish 0
}
-# This test verifies that the binary is reporting its version properly.
-version_test() {
- test_name=${1} # Test name
-
- # Log the start of the test and print test name.
- test_start "${test_suite}-${test_name}"
-
- REPORTED_VERSION=$(${shell_bin_path}/${shell_bin} -v)
-
- if test "${REPORTED_VERSION}" = "${EXPECTED_VERSION}"; then
- test_finish 0
- else
- echo "ERROR:" \
- "Expected version ${EXPECTED_VERSION}, got ${REPORTED_VERSION}"
- test_finish 1
- fi
-}
-
-version_test "shell.version"
shell_command_test "shell.list-commands" "list-commands" \
"[ { \"arguments\": [ \"build-report\", \"config-backend-pull\", \"config-get\", \"config-hash-get\", \"config-reload\", \"config-set\", \"config-test\", \"config-write\", \"dhcp-disable\", \"dhcp-enable\", \"kea-lfc-start\", \"leases-reclaim\", \"list-commands\", \"server-tag-get\", \"shutdown\", \"statistic-get\", \"statistic-get-all\", \"statistic-global-get-all\", \"statistic-remove\", \"statistic-remove-all\", \"statistic-reset\", \"statistic-reset-all\", \"statistic-sample-age-set\", \"statistic-sample-age-set-all\", \"statistic-sample-count-set\", \"statistic-sample-count-set-all\", \"status-get\", \"subnet4-select-test\", \"subnet4o6-select-test\", \"version-get\" ], \"result\": 0 } ]" ""
shell_command_test "shell.bogus" "give-me-a-beer" \
test_finish 0
}
-# This test verifies that the binary is reporting its version properly.
-version_test() {
- test_name=${1} # Test name
-
- # Log the start of the test and print test name.
- test_start "${test_suite}-${test_name}"
-
- REPORTED_VERSION=$(${shell_bin_path}/${shell_bin} -v)
-
- if test "${REPORTED_VERSION}" = "${EXPECTED_VERSION}"; then
- test_finish 0
- else
- echo "ERROR:" \
- "Expected version ${EXPECTED_VERSION}, got ${REPORTED_VERSION}"
- test_finish 1
- fi
-}
-
-version_test "shell.version"
shell_command_test "shell.list-commands" "list-commands" \
"[ { \"arguments\": [ \"build-report\", \"config-backend-pull\", \"config-get\", \"config-hash-get\", \"config-reload\", \"config-set\", \"config-test\", \"config-write\", \"dhcp-disable\", \"dhcp-enable\", \"kea-lfc-start\", \"leases-reclaim\", \"list-commands\", \"server-tag-get\", \"shutdown\", \"statistic-get\", \"statistic-get-all\", \"statistic-global-get-all\", \"statistic-remove\", \"statistic-remove-all\", \"statistic-reset\", \"statistic-reset-all\", \"statistic-sample-age-set\", \"statistic-sample-age-set-all\", \"statistic-sample-count-set\", \"statistic-sample-count-set-all\", \"status-get\", \"subnet6-select-test\", \"version-get\" ], \"result\": 0 } ]" ""
shell_command_test "shell.bogus" "give-me-a-beer" \