You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by "Roger Meier (JIRA)" <ji...@apache.org> on 2014/08/17 17:59:18 UTC
[jira] [Updated] (THRIFT-2668) TestSuite: detailed result on passed
tests by feature
[ https://issues.apache.org/jira/browse/THRIFT-2668?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Roger Meier updated THRIFT-2668:
--------------------------------
Description:
return code shall be 0 on success or an integer in the range 1 - 255 on error
as mentioned http://thrift.apache.org/test
We can define bit fields for the byte we pass as return code:
{noformat}
#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_NOTUSED 240 // 1111 0000
{noformat}
this will help us to see which tests passed
a TestClient will do this:
{noformat}
ret = 255 - TEST_NOTUSED
if testBaseTypes == passed
ret = ret - TEST_BASETYPES
if testStructs == passed
ret = ret - TEST_STRUCTS
if testContainers == passed
ret = ret - TEST_CONTAINERS
if testExceptions == passed
ret = ret - TEST_EXCEPTIONS
return ret
{noformat}
test suite reporting can take care on the individual test status
was:
return code shall be 0 on success or an integer in the range 1 - 255 on error
as mentioned http://thrift.apache.org/test
We can define bit fields for the byte we pass as return code:
{noformat}
#define TEST_BASETYPES 1 // 0000 0001
#define TEST_STRUCTS 2 // 0000 0010
#define TEST_CONTAINERS 4 // 0000 0010
#define TEST_EXCEPTIONS 8 // 0000 0010
#define TEST_NOTUSED 240 // 1111 0000
{noformat}
this will help us to see which tests passed
a TestClient will do this:
{noformat}
ret = 255 - TEST_NOTUSED
if testBaseTypes == passed
ret = ret - TEST_BASETYPES
if testStructs == passed
ret = ret - TEST_STRUCTS
if testContainers == passed
ret = ret - TEST_CONTAINERS
if testExceptions == passed
ret = ret - TEST_EXCEPTIONS
return ret
{noformat}
test suite reporting can take care on the individual test status
> TestSuite: detailed result on passed tests by feature
> -----------------------------------------------------
>
> Key: THRIFT-2668
> URL: https://issues.apache.org/jira/browse/THRIFT-2668
> Project: Thrift
> Issue Type: Sub-task
> Components: Test Suite
> Reporter: Roger Meier
>
> return code shall be 0 on success or an integer in the range 1 - 255 on error
> as mentioned http://thrift.apache.org/test
> We can define bit fields for the byte we pass as return code:
> {noformat}
> #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_NOTUSED 240 // 1111 0000
> {noformat}
> this will help us to see which tests passed
> a TestClient will do this:
> {noformat}
> ret = 255 - TEST_NOTUSED
> if testBaseTypes == passed
> ret = ret - TEST_BASETYPES
> if testStructs == passed
> ret = ret - TEST_STRUCTS
> if testContainers == passed
> ret = ret - TEST_CONTAINERS
> if testExceptions == passed
> ret = ret - TEST_EXCEPTIONS
> return ret
> {noformat}
> test suite reporting can take care on the individual test status
--
This message was sent by Atlassian JIRA
(v6.2#6252)