[
https://issues.apache.org/jira/browse/THRIFT-3366?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14943920#comment-14943920
]
ASF GitHub Bot commented on THRIFT-3366:
----------------------------------------
GitHub user markerickson-wf opened a pull request:
https://github.com/apache/thrift/pull/635
THRIFT-3366 Fix Dart test client to return expected error codes
- Return the expected error code, specific to the test being executed
- Allow tests to continue after failure, and collect the results, bitwise
https://issues.apache.org/jira/browse/THRIFT-3366
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/markerickson-wf/thrift thrift-3366
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/thrift/pull/635.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #635
----
commit 6248f1fe0efd0f8e26e92d1886d73b5ef562e0bf
Author: Mark Erickson <[email protected]>
Date: 2015-10-05T19:33:28Z
Fix Dart test client to return expected error codes.
https://issues.apache.org/jira/browse/THRIFT-3366
----
> ThriftTest to implement standard return values
> -----------------------------------------------
>
> Key: THRIFT-3366
> URL: https://issues.apache.org/jira/browse/THRIFT-3366
> Project: Thrift
> Issue Type: Improvement
> Components: Dart - Library
> Reporter: Jens Geyer
> Assignee: Mark Erickson
> Labels: test-suite
>
> All ThriftTest implementations should implement the return codes as outlined
> in the [test docs|http://thrift.apache.org/test/]
> {quote}
> Return code
> The return code (exit code) shall be 0 on success, or an integer in the range
> 1 - 255 on errors. In order to signal failed tests, the return code shall be
> composed from these bits to indicate failing tests:
> {code}
> #define TEST_BASETYPES 1 // 0000 0001
> #define TEST_STRUCTS 2 // 0000 0010
> #define TEST_CONTAINERS 4 // 0000 0100
> #define TEST_EXCEPTIONS 8 // 0000 1000
> #define TEST_UNKNOWN 64 // 0100 0000 (Failed to prepare environment
> etc.)
> #define TEST_TIMEOUT 128 // 1000 0000
> #define TEST_NOTUSED 48 // 0011 0000 (reserved bits)
> {code}
> Tests that have not been executed at all count as errors.
> Example:
> During tests, the test client notices that some of the Struct tests fail.
> Furthermore, due to some other problem none of the Exception tests is
> executed. Therefore, the test client returns the code 10 = 2 | 8, indicating
> the failure of both test 2 (TEST_STRUCTS) and test 8 (TEST_EXCEPTIONS).
> {quote}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)