diff options
author | Kyungwook Tak <k.tak@samsung.com> | 2016-03-09 18:11:15 +0900 |
---|---|---|
committer | Kyungwook Tak <k.tak@samsung.com> | 2016-03-09 18:11:15 +0900 |
commit | 789fc17ac1d5641a8d82b429b1785f9a6c2b4097 (patch) | |
tree | 9121ae69de51eb407e7c64d7397bf5f1b80daddb /test | |
parent | d6af2fe1baed9c782fc492936718ed6d0303bbee (diff) | |
download | libcryptsvc-789fc17ac1d5641a8d82b429b1785f9a6c2b4097.tar.gz libcryptsvc-789fc17ac1d5641a8d82b429b1785f9a6c2b4097.tar.bz2 libcryptsvc-789fc17ac1d5641a8d82b429b1785f9a6c2b4097.zip |
Fix warning and add warning related gcc optionssubmit/tizen_unified/20170308.100409submit/tizen_3.0_wearable/20161015.000003submit/tizen_3.0_tv/20161015.000003submit/tizen_3.0_mobile/20161015.000003submit/tizen_3.0_ivi/20161010.000003submit/tizen_3.0_common/20161104.104000submit/tizen_3.0.m2/20170104.093751submit/tizen/20160310.050225accepted/tizen/wearable/20160310.063353accepted/tizen/unified/20170309.033936accepted/tizen/tv/20160310.063326accepted/tizen/mobile/20160310.063244accepted/tizen/ivi/20160310.063418accepted/tizen/common/20160311.201051accepted/tizen/3.0/wearable/20161015.083245accepted/tizen/3.0/tv/20161016.005025accepted/tizen/3.0/mobile/20161015.033524accepted/tizen/3.0/ivi/20161011.044347accepted/tizen/3.0/common/20161114.110008accepted/tizen/3.0.m2/wearable/20170104.142432accepted/tizen/3.0.m2/tv/20170104.142139accepted/tizen/3.0.m2/mobile/20170104.141807tizen_3.0_tvtizen_3.0.m2tizen_3.0accepted/tizen_wearableaccepted/tizen_tvaccepted/tizen_mobileaccepted/tizen_iviaccepted/tizen_commonaccepted/tizen_3.0_wearableaccepted/tizen_3.0_tvaccepted/tizen_3.0_mobileaccepted/tizen_3.0_iviaccepted/tizen_3.0_commonaccepted/tizen_3.0.m2_wearableaccepted/tizen_3.0.m2_tvaccepted/tizen_3.0.m2_mobile
Change-Id: Ieccac38280db7aff3094a6ea84907e48c44d3446
Signed-off-by: Kyungwook Tak <k.tak@samsung.com>
Diffstat (limited to 'test')
-rw-r--r-- | test/colour_log_formatter.cc | 34 |
1 files changed, 10 insertions, 24 deletions
diff --git a/test/colour_log_formatter.cc b/test/colour_log_formatter.cc index 9274c49..50857a7 100644 --- a/test/colour_log_formatter.cc +++ b/test/colour_log_formatter.cc @@ -29,24 +29,10 @@ namespace cryptsvc { namespace { -const char* BOLD_GREEN_BEGIN = "\033[1;32m"; -const char* BOLD_GREEN_END = "\033[m"; -const char* RED_BEGIN = "\033[0;31m"; -const char* RED_END = "\033[m"; -const char* PURPLE_BEGIN = "\033[0;35m"; -const char* PURPLE_END = "\033[m"; -const char* GREEN_BEGIN = "\033[0;32m"; -const char* GREEN_END = "\033[m"; -const char* CYAN_BEGIN = "\033[0;36m"; -const char* CYAN_END = "\033[m"; -const char* BOLD_RED_BEGIN = "\033[1;31m"; -const char* BOLD_RED_END = "\033[m"; -const char* BOLD_YELLOW_BEGIN = "\033[1;33m"; -const char* BOLD_YELLOW_END = "\033[m"; -const char* BOLD_GOLD_BEGIN = "\033[0;33m"; -const char* BOLD_GOLD_END = "\033[m"; -const char* BOLD_WHITE_BEGIN = "\033[1;37m"; -const char* BOLD_WHITE_END = "\033[m"; +const char* COLOR_RED = "\033[0;31m"; +const char* COLOR_GREEN = "\033[0;32m"; +const char* COLOR_CYAN = "\033[0;36m"; +const char* COLOR_BOLD_YELLOW = "\033[1;33m"; const char* COLOR_END = "\033[m"; const_string @@ -128,16 +114,16 @@ colour_log_formatter::test_unit_finish( output << "Finished test " << tu.p_type_name << " \"" << tu.p_name << "\""<< std::endl; return; } - std::string color = GREEN_BEGIN; + std::string color = COLOR_GREEN; std::string status = "OK"; if (m_isTestCaseFailed) { - color = RED_BEGIN; + color = COLOR_RED; status = "FAIL"; } output << "\t" << "[ " << color << status << COLOR_END << " ]"; - output << ", " << CYAN_BEGIN << "time: "; + output << ", " << COLOR_CYAN << "time: "; if( elapsed > 0 ) { if( elapsed % 1000 == 0 ) output << elapsed/1000 << "ms"; @@ -170,7 +156,7 @@ colour_log_formatter::log_exception( boost::execution_exception const& ex ) { boost::execution_exception::location const& loc = ex.where(); - output << '\t' << BOLD_YELLOW_BEGIN << get_basename(loc.m_file_name) + output << '\t' << COLOR_BOLD_YELLOW << get_basename(loc.m_file_name) << '(' << loc.m_line_num << "), "; output << "fatal error in \"" @@ -210,13 +196,13 @@ colour_log_formatter::log_entry_start( output << "warning in \"" << test_phase_identifier() << "\": "; break; case BOOST_UTL_ET_ERROR: - output << '\t' << BOLD_YELLOW_BEGIN << get_basename(entry_data.m_file_name) + output << '\t' << COLOR_BOLD_YELLOW << get_basename(entry_data.m_file_name) << '(' << entry_data.m_line_num << "), "; output << "error in \"" << test_phase_identifier() << "\": "; m_isTestCaseFailed = true; break; case BOOST_UTL_ET_FATAL_ERROR: - output << '\t' << BOLD_YELLOW_BEGIN << get_basename(entry_data.m_file_name) + output << '\t' << COLOR_BOLD_YELLOW << get_basename(entry_data.m_file_name) << '(' << entry_data.m_line_num << "), "; output << " fatal error in \"" << test_phase_identifier() << "\": "; m_isTestCaseFailed = true; |