Skip to content

Commit

Permalink
enum型の変更とバージョンアップ方法の使い方解説、および、自動テスト実装完了 Issue #25
Browse files Browse the repository at this point in the history
  バージョン名の"-Prerelease."を解除。

全ビルド中にミス発見して修正
  テスト・ケースが増えているため、windows.cmakeとlinux.cmakeのテスト数を更新した。
  test_report1.cppの現在時刻獲得方法がWorkLogのそれと異なるため、ubuntuにて誤差でFAILしたと思われる。
  時刻獲得方法をWorkLogと同じ方法に変更した。
  typo修正

----------------- MD5 Hash Values -----------------
TheolizerDriver  : 652d5d139c8962bfe144dc9356b1b27a
TheolizerLibrary : 60445ca5d58a28deaeed0b89cfbc2eff
Library's Header : 0cfd664e60f76c8df99159577d108fef
  • Loading branch information
yossi-tahara committed Mar 8, 2017
1 parent 7ce1b3f commit 16805a3
Show file tree
Hide file tree
Showing 9 changed files with 54 additions and 34 deletions.
6 changes: 3 additions & 3 deletions build_tools/linux.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -109,12 +109,12 @@ set(ENV{LC_ALL} "C")
#-----------------------------------------------------------------------------

output_title("****** StaticWithBoost ******")
build_by_gcc(gcc540 64 StaticWithBoost TRUE TRUE "13 1" "11 1")
build_by_gcc(gcc540 64 StaticWithBoost TRUE TRUE "32 1" "11 1")

output_title("****** Static ******")
build_by_gcc(gcc540 64 Static FALSE FALSE "13 1" "11 1")
build_by_gcc(gcc540 64 Static FALSE FALSE "32 1" "11 1")

output_title("****** Shared ******")
build_by_gcc(gcc540 64 Shared FALSE FALSE "13 1" "11 1")
build_by_gcc(gcc540 64 Shared FALSE FALSE "32 1" "11 1")

output_summary()
24 changes: 12 additions & 12 deletions build_tools/windows.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -109,21 +109,21 @@ file(WRITE ${SUMMARY} "")
#-----------------------------------------------------------------------------

#output_title("****** StaticWithBoost ******")
build_by_msvc(msvc2015 64 StaticWithBoost TRUE TRUE "13 11 1 1")
build_by_msvc(msvc2015 32 StaticWithBoost TRUE TRUE "13 11 1 1")
build_by_gcc( mingw540 64 StaticWithBoost TRUE TRUE "13 1" "11 1")
build_by_gcc( mingw540 32 StaticWithBoost TRUE TRUE "13 1" "11 1")
build_by_msvc(msvc2015 64 StaticWithBoost TRUE TRUE "32 11 1 1")
build_by_msvc(msvc2015 32 StaticWithBoost TRUE TRUE "32 11 1 1")
build_by_gcc( mingw540 64 StaticWithBoost TRUE TRUE "32 1" "11 1")
build_by_gcc( mingw540 32 StaticWithBoost TRUE TRUE "32 1" "11 1")

output_title("****** Static ******")
build_by_msvc(msvc2015 64 Static FALSE FALSE "13 11 1 1")
build_by_msvc(msvc2015 32 Static FALSE FALSE "13 11 1 1")
build_by_gcc( mingw540 64 Static FALSE FALSE "13 1" "11 1")
build_by_gcc( mingw540 32 Static FALSE FALSE "13 1" "11 1")
build_by_msvc(msvc2015 64 Static FALSE FALSE "32 11 1 1")
build_by_msvc(msvc2015 32 Static FALSE FALSE "32 11 1 1")
build_by_gcc( mingw540 64 Static FALSE FALSE "32 1" "11 1")
build_by_gcc( mingw540 32 Static FALSE FALSE "32 1" "11 1")

output_title("****** Shared ******")
build_by_msvc(msvc2015 64 Shared FALSE FALSE "13 11 1 1")
build_by_msvc(msvc2015 32 Shared FALSE FALSE "13 11 1 1")
build_by_gcc( mingw540 64 Shared FALSE FALSE "13 1" "11 1")
build_by_gcc( mingw540 32 Shared FALSE FALSE "13 1" "11 1")
build_by_msvc(msvc2015 64 Shared FALSE FALSE "32 11 1 1")
build_by_msvc(msvc2015 32 Shared FALSE FALSE "32 11 1 1")
build_by_gcc( mingw540 64 Shared FALSE FALSE "32 1" "11 1")
build_by_gcc( mingw540 32 Shared FALSE FALSE "32 1" "11 1")

output_summary()
2 changes: 1 addition & 1 deletion build_tools/zy0_full_all.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
echo "root is necessary for this."
sudo echo "than you."
sudo echo "thank you."

cmake -DPROC_ALL=full_all -P linux.cmake

Expand Down
2 changes: 1 addition & 1 deletion build_tools/zy3_last_all.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
echo "root is necessary for this."
sudo echo "than you."
sudo echo "thank you."

cmake -DPROC_ALL=last_all -P linux.cmake
2 changes: 1 addition & 1 deletion source/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ message(STATUS "CI_SERVICE =${CI_SERVICE}")
#-----------------------------------------------------------------------------

project(Theolizer VERSION 0.4.4)
set(TEMPORARY_VERSION "-Prerelease.")
#set(TEMPORARY_VERSION "-Prerelease.")

message(STATUS "PROJECT_VERSION=${PROJECT_VERSION}${TEMPORARY_VERSION}")

Expand Down
20 changes: 19 additions & 1 deletion source/library/theolizer/internal/report.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -801,7 +801,8 @@ WorkingLog::LogStream::LogStream(WorkingLog::LogStream&& iRhs) :

WorkingLog::LogStream::~LogStream() noexcept
{
if (mWorkingLog) {
if (mWorkingLog)
{
mWorkingLog->getOStream() << std::endl;

// ロック開放
Expand All @@ -813,6 +814,23 @@ WorkingLog::LogStream::~LogStream() noexcept
// Theolizerログ
// ***************************************************************************

//----------------------------------------------------------------------------
// 現在時刻獲得(ログ・システムと同じ時間計測方法で獲得する)
//----------------------------------------------------------------------------

time_t WorkingLog::getTime(bool iIsUTC)
{
// 現在時刻獲得
stdC::system_clock::time_point aNowDateTime = stdC::system_clock::now();
time_t aTime = stdC::system_clock::to_time_t(aNowDateTime);
if (iIsUTC)
{
struct tm aTm=internal::getGmTime(aTime);
aTime=mktime(&aTm);
}
return aTime;
}

//----------------------------------------------------------------------------
// コンストラクタ
//----------------------------------------------------------------------------
Expand Down
4 changes: 4 additions & 0 deletions source/library/theolizer/report.h
Original file line number Diff line number Diff line change
Expand Up @@ -402,6 +402,10 @@ class THEOLIZER_INTERNAL_DLL WorkingLog
//! @todo T.B.D.
LogStream getLogStream();

// 現在時刻獲得(ログ・システムと同じ時間計測方法で獲得する)
//! @todo T.B.D.
static time_t getTime(bool iIsUTC=false);

//----------------------------------------------------------------------------
// 行ヘッダ解析
//----------------------------------------------------------------------------
Expand Down
18 changes: 9 additions & 9 deletions source/reference_and_test/disable_test.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,15 @@
// basicテストの有効/無効
// ***************************************************************************

#define DISABLE_BASIC_PROCESS_TEST
#define DISABLE_CLASS_VARIATION_TEST
#define DISABLE_ENUM_VARIATION_TEST
#define DISABLE_OBJECT_TRACKING_TEST
#define DISABLE_OBJECT_TRACKING2_TEST
#define DISABLE_OBJECT_TRACKING3_TEST
#define DISABLE_POLYMORPHISM_TEST
#define DISABLE_DESTINATIONS_TEST
#define DISABLE_SUPPORT_STL_TEST
//#define DISABLE_BASIC_PROCESS_TEST
//#define DISABLE_CLASS_VARIATION_TEST
//#define DISABLE_ENUM_VARIATION_TEST
//#define DISABLE_OBJECT_TRACKING_TEST
//#define DISABLE_OBJECT_TRACKING2_TEST
//#define DISABLE_OBJECT_TRACKING3_TEST
//#define DISABLE_POLYMORPHISM_TEST
//#define DISABLE_DESTINATIONS_TEST
//#define DISABLE_SUPPORT_STL_TEST

// ***************************************************************************
// 変更テストの有効/無効
Expand Down
10 changes: 4 additions & 6 deletions source/test_library/report/test_report1.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -152,9 +152,9 @@ int main(int argc, char** argv)

// ---<<< ログ出力 >>>---

time_t aDateTime; time(&aDateTime); // localtimeで返却される
time_t aDateTime =theolizer::WorkingLog::getTime();
THEOLIZER_INTERNAL_WARNING("Error Message"); unsigned line=__LINE__;
time_t aLastDateTime; time(&aLastDateTime); // localtimeで返却される
time_t aLastDateTime=theolizer::WorkingLog::getTime();

// ---<<< 確認 >>>---

Expand Down Expand Up @@ -386,8 +386,7 @@ int main(int argc, char** argv)
int aLogNo=0;

// 現在時刻設定
time_t aDateTime; time(&aDateTime); // localtimeで返却される
aDateTime = mktime(gmtime(&aDateTime)); // UTC(GMT)へ変換
time_t aDateTime=theolizer::WorkingLog::getTime(true);
uint32_t aMilliseconds=0;

for (int aSetNo=0; aSetNo < kSetCount; ++aSetNo)
Expand Down Expand Up @@ -418,8 +417,7 @@ int main(int argc, char** argv)
//std::cout << "--- output log ended\n";

// 終了時刻設定
time_t aLastDateTime; time(&aLastDateTime); // localtimeで返却される
aLastDateTime = mktime(gmtime(&aLastDateTime)); // UTC(GMT)へ変換
time_t aLastDateTime=theolizer::WorkingLog::getTime(true);

//結果確認
for (int no=0; no < 2; ++no)
Expand Down

0 comments on commit 16805a3

Please sign in to comment.