Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/bsd/atf/dist Post-import merge of atf 0.16.
details: https://anonhg.NetBSD.org/src/rev/9a4d505803a4
branches: trunk
changeset: 780095:9a4d505803a4
user: jmmv <jmmv%NetBSD.org@localhost>
date: Wed Jul 11 22:38:40 2012 +0000
description:
Post-import merge of atf 0.16.
diffstat:
external/bsd/atf/dist/atf-c/detail/test_helpers.c | 18 +++++++++++-------
external/bsd/atf/dist/atf-run/test_program_test.cpp | 2 ++
external/bsd/atf/dist/atf-sh/atf-check.cpp | 2 +-
external/bsd/atf/dist/atf-version/atf-version.cpp | 2 +-
4 files changed, 15 insertions(+), 9 deletions(-)
diffs (92 lines):
diff -r 12b717c58787 -r 9a4d505803a4 external/bsd/atf/dist/atf-c/detail/test_helpers.c
--- a/external/bsd/atf/dist/atf-c/detail/test_helpers.c Wed Jul 11 22:37:05 2012 +0000
+++ b/external/bsd/atf/dist/atf-c/detail/test_helpers.c Wed Jul 11 22:38:40 2012 +0000
@@ -46,33 +46,37 @@
static
void
-build_check_c_o_aux(const char *path, const char *failmsg)
+build_check_c_o_aux(const char *path, const char *failmsg,
+ const bool expect_pass)
{
bool success;
atf_dynstr_t iflag;
- const char *optargs[2];
+ const char *optargs[4];
RE(atf_dynstr_init_fmt(&iflag, "-I%s", atf_config_get("atf_includedir")));
optargs[0] = atf_dynstr_cstring(&iflag);
- optargs[1] = NULL;
+ optargs[1] = "-Wall";
+ optargs[2] = "-Werror";
+ optargs[3] = NULL;
RE(atf_check_build_c_o(path, "test.o", optargs, &success));
atf_dynstr_fini(&iflag);
- if (!success)
+ if ((expect_pass && !success) || (!expect_pass && success))
atf_tc_fail("%s", failmsg);
}
void
-build_check_c_o(const atf_tc_t *tc, const char *sfile, const char *failmsg)
+build_check_c_o(const atf_tc_t *tc, const char *sfile, const char *failmsg,
+ const bool expect_pass)
{
atf_fs_path_t path;
RE(atf_fs_path_init_fmt(&path, "%s/%s",
atf_tc_get_config_var(tc, "srcdir"), sfile));
- build_check_c_o_aux(atf_fs_path_cstring(&path), failmsg);
+ build_check_c_o_aux(atf_fs_path_cstring(&path), failmsg, expect_pass);
atf_fs_path_fini(&path);
}
@@ -90,7 +94,7 @@
snprintf(failmsg, sizeof(failmsg),
"Header check failed; %s is not self-contained", hdrname);
- build_check_c_o_aux("test.c", failmsg);
+ build_check_c_o_aux("test.c", failmsg, true);
}
void
diff -r 12b717c58787 -r 9a4d505803a4 external/bsd/atf/dist/atf-run/test_program_test.cpp
--- a/external/bsd/atf/dist/atf-run/test_program_test.cpp Wed Jul 11 22:37:05 2012 +0000
+++ b/external/bsd/atf/dist/atf-run/test_program_test.cpp Wed Jul 11 22:38:40 2012 +0000
@@ -1008,6 +1008,8 @@
ATF_ADD_TEST_CASE(tcs, parse_test_case_result_skipped);
ATF_ADD_TEST_CASE(tcs, parse_test_case_result_unknown);
+ ATF_ADD_TEST_CASE(tcs, read_test_case_result_failed);
+ ATF_ADD_TEST_CASE(tcs, read_test_case_result_skipped);
ATF_ADD_TEST_CASE(tcs, read_test_case_result_no_file);
ATF_ADD_TEST_CASE(tcs, read_test_case_result_empty_file);
ATF_ADD_TEST_CASE(tcs, read_test_case_result_multiline);
diff -r 12b717c58787 -r 9a4d505803a4 external/bsd/atf/dist/atf-sh/atf-check.cpp
--- a/external/bsd/atf/dist/atf-sh/atf-check.cpp Wed Jul 11 22:37:05 2012 +0000
+++ b/external/bsd/atf/dist/atf-sh/atf-check.cpp Wed Jul 11 22:38:40 2012 +0000
@@ -271,7 +271,7 @@
else
value = parse_signal(value_str);
} else
- throw atf::application::usage_error("Invalid output checker");
+ throw atf::application::usage_error("Invalid status checker");
return status_check(type, negated, value);
}
diff -r 12b717c58787 -r 9a4d505803a4 external/bsd/atf/dist/atf-version/atf-version.cpp
--- a/external/bsd/atf/dist/atf-version/atf-version.cpp Wed Jul 11 22:37:05 2012 +0000
+++ b/external/bsd/atf/dist/atf-version/atf-version.cpp Wed Jul 11 22:38:40 2012 +0000
@@ -69,7 +69,7 @@
#if defined(PACKAGE_REVISION_TYPE_DIST)
std::cout << format_text("Built from a distribution file; no revision "
"information available.") << "\n";
-#elif defined(PACKAGE_REVISION_TYPE_MTN)
+#elif defined(PACKAGE_REVISION_TYPE_GIT)
std::cout << format_text_with_tag(PACKAGE_REVISION_BRANCH, "Branch: ",
false) << "\n";
std::cout << format_text_with_tag(PACKAGE_REVISION_BASE
Home |
Main Index |
Thread Index |
Old Index