Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/tests/ipf Add another test option for expected failures, rat...



details:   https://anonhg.NetBSD.org/src/rev/bf357397e69f
branches:  trunk
changeset: 782971:bf357397e69f
user:      pgoyette <pgoyette%NetBSD.org@localhost>
date:      Thu Nov 29 17:10:21 2012 +0000

description:
Add another test option for expected failures, rather than simply
skipping tests

diffstat:

 tests/ipf/h_common.sh |  15 ++++++++++++++-
 1 files changed, 14 insertions(+), 1 deletions(-)

diffs (26 lines):

diff -r 3e2faa9f45ef -r bf357397e69f tests/ipf/h_common.sh
--- a/tests/ipf/h_common.sh     Thu Nov 29 16:18:35 2012 +0000
+++ b/tests/ipf/h_common.sh     Thu Nov 29 17:10:21 2012 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: h_common.sh,v 1.3 2010/11/07 17:51:19 jmmv Exp $
+# $NetBSD: h_common.sh,v 1.4 2012/11/29 17:10:21 pgoyette Exp $
 #
 # Copyright (c) 2008, 2010 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -62,3 +62,16 @@
                ${check_function} '${name}' " "${@}" "; \
        }"
 }
+
+failing_test_case()
+{
+       local name="${1}"; shift
+       local check_function="${1}"; shift
+       local reason="${1}; shift
+
+       atf_test_case "${name}"
+       eval "${name}_body() { \
+               atf_tc_expect_fail "${reason}"; \
+               ${check_function} '${name}' " "${@}" "; \
+       }"
+}



Home | Main Index | Thread Index | Old Index