Pull up 702fa99a25c1b27e4c501e4a504f36b74106ea97 from upstream
This reverts the default timeout for test cases back to 300 seconds. The change in the release was quite blind because it did not anticipate many existing tests to be slow enough to overflow the modified timeout (30 seconds), specially in anita. My plan to really fix this is to let test cases specify their sizes in a declarative way instead of specifying timeouts in seconds (the timeout being defined by atf-run on a size basis), so I'm not going to bother to go over all existing tests trying to figure out which ones need a higher timeout for now. It is just easier to revert.
This commit is contained in:
parent
d0e6f50de3
commit
9e95dfadb1
@ -110,7 +110,7 @@ class metadata_reader : public detail::atf_tp_reader {
|
||||
m_tcs[ident].insert(std::make_pair("has.cleanup", "false"));
|
||||
|
||||
if (m_tcs[ident].find("timeout") == m_tcs[ident].end())
|
||||
m_tcs[ident].insert(std::make_pair("timeout", "30"));
|
||||
m_tcs[ident].insert(std::make_pair("timeout", "300"));
|
||||
}
|
||||
|
||||
public:
|
||||
|
@ -190,7 +190,7 @@ ATF_TEST_CASE_BODY(tp_2)
|
||||
"\n"
|
||||
"ident: test_case_1\n"
|
||||
"descr: This is the description\n"
|
||||
"timeout: 30\n"
|
||||
"timeout: 300\n"
|
||||
"\n"
|
||||
"ident: test_case_2\n"
|
||||
"\n"
|
||||
@ -201,7 +201,7 @@ ATF_TEST_CASE_BODY(tp_2)
|
||||
|
||||
// NO_CHECK_STYLE_BEGIN
|
||||
const char* exp_calls[] = {
|
||||
"got_tc(test_case_1, {descr=This is the description, ident=test_case_1, timeout=30})",
|
||||
"got_tc(test_case_1, {descr=This is the description, ident=test_case_1, timeout=300})",
|
||||
"got_tc(test_case_2, {ident=test_case_2})",
|
||||
"got_tc(test_case_3, {X-prop1=A custom property, descr=Third test case, ident=test_case_3})",
|
||||
"got_eof()",
|
||||
@ -224,7 +224,7 @@ ATF_TEST_CASE_BODY(tp_3)
|
||||
"\n"
|
||||
"ident: single_test\n"
|
||||
"descr: Some description\n"
|
||||
"timeout: 30\n"
|
||||
"timeout: 300\n"
|
||||
"require.arch: thearch\n"
|
||||
"require.config: foo-bar\n"
|
||||
"require.machine: themachine\n"
|
||||
@ -234,7 +234,7 @@ ATF_TEST_CASE_BODY(tp_3)
|
||||
|
||||
// NO_CHECK_STYLE_BEGIN
|
||||
const char* exp_calls[] = {
|
||||
"got_tc(single_test, {descr=Some description, ident=single_test, require.arch=thearch, require.config=foo-bar, require.machine=themachine, require.progs=/bin/cp mv, require.user=root, timeout=30})",
|
||||
"got_tc(single_test, {descr=Some description, ident=single_test, require.arch=thearch, require.config=foo-bar, require.machine=themachine, require.progs=/bin/cp mv, require.user=root, timeout=300})",
|
||||
"got_eof()",
|
||||
NULL
|
||||
};
|
||||
@ -474,7 +474,7 @@ ATF_TEST_CASE_BODY(tp_59)
|
||||
"\n"
|
||||
"\n"
|
||||
"ident: test\n"
|
||||
"timeout: 30\n"
|
||||
"timeout: 300\n"
|
||||
;
|
||||
|
||||
const char* exp_calls[] = {
|
||||
@ -762,7 +762,7 @@ ATF_TEST_CASE_BODY(get_metadata_several_tcs) {
|
||||
check_property((*iter).second, "descr", "Description 1");
|
||||
check_property((*iter).second, "has.cleanup", "false");
|
||||
check_property((*iter).second, "ident", "first");
|
||||
check_property((*iter).second, "timeout", "30");
|
||||
check_property((*iter).second, "timeout", "300");
|
||||
}
|
||||
|
||||
{
|
||||
@ -786,7 +786,7 @@ ATF_TEST_CASE_BODY(get_metadata_several_tcs) {
|
||||
ATF_REQUIRE_EQ(3, (*iter).second.size());
|
||||
check_property((*iter).second, "has.cleanup", "false");
|
||||
check_property((*iter).second, "ident", "third");
|
||||
check_property((*iter).second, "timeout", "30");
|
||||
check_property((*iter).second, "timeout", "300");
|
||||
}
|
||||
}
|
||||
|
||||
|
4
external/bsd/atf/dist/doc/atf-test-case.4
vendored
4
external/bsd/atf/dist/doc/atf-test-case.4
vendored
@ -26,7 +26,7 @@
|
||||
.\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
|
||||
.\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
.\"
|
||||
.Dd October 31, 2010
|
||||
.Dd November 16, 2010
|
||||
.Dt ATF-TEST-CASE 4
|
||||
.Os
|
||||
.Sh NAME
|
||||
@ -230,7 +230,7 @@ unprivileged user will be supported.
|
||||
.It timeout
|
||||
Type: integral.
|
||||
Optional; defaults to
|
||||
.Sq 30 .
|
||||
.Sq 300 .
|
||||
.Pp
|
||||
Specifies the maximum amount of time the test case can run.
|
||||
This is particularly useful because some tests can stall either because they
|
||||
|
Loading…
Reference in New Issue
Block a user