mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-03 07:28:54 +08:00
Testing: use return value to check if controllib tests failed
This commit is contained in:
committed by
Lorenz Meier
parent
a2c493efc7
commit
1999ed2601
@@ -69,25 +69,26 @@ int blockDelayTest();
|
||||
|
||||
int basicBlocksTest()
|
||||
{
|
||||
blockLimitTest();
|
||||
blockLimitSymTest();
|
||||
blockLowPassTest();
|
||||
blockHighPassTest();
|
||||
blockLowPass2Test();
|
||||
blockIntegralTest();
|
||||
blockIntegralTrapTest();
|
||||
blockDerivativeTest();
|
||||
blockPTest();
|
||||
blockPITest();
|
||||
blockPDTest();
|
||||
blockPIDTest();
|
||||
blockOutputTest();
|
||||
//blockRandUniformTest();
|
||||
bool failed = false;
|
||||
failed = failed || blockLimitTest() < 0;
|
||||
failed = failed || blockLimitSymTest() < 0;
|
||||
failed = failed || blockLowPassTest() < 0;
|
||||
failed = failed || blockHighPassTest() < 0;
|
||||
failed = failed || blockLowPass2Test() < 0;
|
||||
failed = failed || blockIntegralTest() < 0;
|
||||
failed = failed || blockIntegralTrapTest() < 0;
|
||||
failed = failed || blockDerivativeTest() < 0;
|
||||
failed = failed || blockPTest() < 0;
|
||||
failed = failed || blockPITest() < 0;
|
||||
failed = failed || blockPDTest() < 0;
|
||||
failed = failed || blockPIDTest() < 0;
|
||||
failed = failed || blockOutputTest() < 0;
|
||||
// known failures
|
||||
// blockRandGaussTest();
|
||||
blockStatsTest();
|
||||
blockDelayTest();
|
||||
return 0;
|
||||
//failed = failed || blockRandUniformTest() < 0;
|
||||
//failed = failed || blockRandGaussTest() < 0;
|
||||
failed = failed || blockStatsTest() < 0;
|
||||
failed = failed || blockDelayTest() < 0;
|
||||
return failed ? -1 : 0;
|
||||
}
|
||||
|
||||
int blockLimitTest()
|
||||
|
||||
Reference in New Issue
Block a user