Merge pull request #2818 from pan-/fix_test_tools_warnings

TESTS TOOLS - fix warnings
pull/2822/head^2
Sam Grove 2016-09-27 21:54:53 -07:00 committed by GitHub
commit 75cf25056c
6 changed files with 9 additions and 6 deletions

View File

@ -10,4 +10,4 @@ public:
};
extern SingletonPtr<GreenteaSerial> greentea_serial;
#endif
#endif

View File

@ -35,10 +35,13 @@ typedef struct {
// Mutex to protect "buf"
SingletonPtr<Mutex> mutex;
#if defined(MBED_STACK_STATS_ENABLED) && MBED_STACK_STATS_ENABLED
static char buf[128];
static SingletonPtr<CircularBuffer<thread_info_t, THREAD_BUF_COUNT> > queue;
#endif
static void send_heap_info(void);
#if defined(MBED_STACK_STATS_ENABLED) && MBED_STACK_STATS_ENABLED
static void send_stack_info(void);
static void on_thread_terminate(osThreadId id);
static void enqeue_thread_info(osThreadId id);
@ -47,6 +50,7 @@ static void deque_and_print_thread_info(void);
// sprintf uses a lot of stack so use these instead
static uint32_t print_hex(char *buf, uint32_t value);
static uint32_t print_dec(char *buf, uint32_t value);
#endif
void greentea_metrics_setup()
{
@ -71,6 +75,7 @@ static void send_heap_info()
greentea_send_kv("max_heap_usage",heap_stats.max_size);
}
#if defined(MBED_STACK_STATS_ENABLED) && MBED_STACK_STATS_ENABLED
MBED_UNUSED static void send_stack_info()
{
mutex->lock();
@ -205,3 +210,5 @@ static uint32_t print_dec(char *buf, uint32_t value)
return pos;
}
#endif

View File

@ -2,4 +2,4 @@
SingletonPtr<GreenteaSerial> greentea_serial;
GreenteaSerial::GreenteaSerial() : mbed::RawSerial(USBTX, USBRX) {};
GreenteaSerial::GreenteaSerial() : mbed::RawSerial(USBTX, USBRX) {};

View File

@ -574,7 +574,6 @@ int greentea_parse_kv(char *out_key,
break;
}
}
return 0;
}
/**

View File

@ -144,7 +144,6 @@ bool Harness::run(const Specification& specification)
if (handlers->test_teardown) handlers->test_teardown(0, 0, failure);
test_cases = NULL;
exit(1);
return true;
}
notify_testcases();
@ -159,7 +158,6 @@ bool Harness::run(const Specification& specification)
if (handlers->test_teardown) handlers->test_teardown(0, 0, failure);
test_cases = NULL;
exit(1);
return true;
}
return true;
}

View File

@ -123,7 +123,6 @@ static int32_t utest_us_ticker_run()
callback();
}
}
return 0;
}