Module Name: src
Committed By: jmmv
Date: Sun Nov 7 17:54:03 UTC 2010
Modified Files:
src/external/bsd/atf/dist/atf-run: config_test.cpp integration_test.sh
Log Message:
Pull in post-release fix 3d5597b0076ade841abf03fc274da72d17cb3ad6 to resolve
issues with the default NetBSD settings. Tests were producing invalid results
because they were unexpectedly reading the system-wide settings.
To generate a diff of this commit:
cvs rdiff -u -r1.1.1.2 -r1.2 \
src/external/bsd/atf/dist/atf-run/config_test.cpp
cvs rdiff -u -r1.1.1.3 -r1.2 \
src/external/bsd/atf/dist/atf-run/integration_test.sh
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/external/bsd/atf/dist/atf-run/config_test.cpp
diff -u src/external/bsd/atf/dist/atf-run/config_test.cpp:1.1.1.2 src/external/bsd/atf/dist/atf-run/config_test.cpp:1.2
--- src/external/bsd/atf/dist/atf-run/config_test.cpp:1.1.1.2 Wed Oct 20 09:14:23 2010
+++ src/external/bsd/atf/dist/atf-run/config_test.cpp Sun Nov 7 17:54:03 2010
@@ -27,7 +27,9 @@
// IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
//
+#include "atf-c++/detail/env.hpp"
#include "atf-c++/detail/test_helpers.hpp"
+#include "atf-c++/config.hpp"
#include "atf-c++/macros.hpp"
#include "config.hpp"
@@ -37,6 +39,14 @@
using atf::tests::vars_map;
+namespace atf {
+namespace config {
+
+void __reinit(void);
+
+} // namespace config
+} // namespace atf
+
// -------------------------------------------------------------------------
// Tests for the "config" parser.
// -------------------------------------------------------------------------
@@ -351,6 +361,8 @@
ATF_TEST_CASE(read_config_files_none);
ATF_TEST_CASE_HEAD(read_config_files_none) {}
ATF_TEST_CASE_BODY(read_config_files_none) {
+ atf::env::set("ATF_CONFDIR", ".");
+ atf::config::__reinit();
ATF_REQUIRE(vars_map() == impl::read_config_files("test-suite"));
}
Index: src/external/bsd/atf/dist/atf-run/integration_test.sh
diff -u src/external/bsd/atf/dist/atf-run/integration_test.sh:1.1.1.3 src/external/bsd/atf/dist/atf-run/integration_test.sh:1.2
--- src/external/bsd/atf/dist/atf-run/integration_test.sh:1.1.1.3 Sun Nov 7 17:43:28 2010
+++ src/external/bsd/atf/dist/atf-run/integration_test.sh Sun Nov 7 17:54:03 2010
@@ -29,6 +29,8 @@
create_atffile()
{
+ ATF_CONFDIR="$(pwd)"; export ATF_CONFDIR
+
cat >Atffile <<EOF
Content-Type: application/X-atf-atffile; version="1"