This commit is contained in:
wieslawsoltes 2018-03-09 14:20:45 +00:00
Родитель 2ea1eeb1ee
Коммит 4ed89d52f4
12 изменённых файлов: 431 добавлений и 29 удалений

Просмотреть файл

@ -200,7 +200,6 @@
<ClCompile Include="worker\InputPathTests.cpp" />
<ClCompile Include="worker\LuaOutputParserTests.cpp" />
<ClCompile Include="worker\LuaProgessTests.cpp" />
<ClCompile Include="worker\OutputParserTests.cpp" />
<ClCompile Include="worker\OutputPathTests.cpp" />
<ClCompile Include="worker\PipeToFileWriterTests.cpp" />
<ClCompile Include="worker\PipeToStringWriterTests.cpp" />

Просмотреть файл

@ -77,9 +77,6 @@
<ClCompile Include="worker\LuaProgessTests.cpp">
<Filter>Source Files\Worker</Filter>
</ClCompile>
<ClCompile Include="worker\OutputParserTests.cpp">
<Filter>Source Files\Worker</Filter>
</ClCompile>
<ClCompile Include="worker\OutputPathTests.cpp">
<Filter>Source Files\Worker</Filter>
</ClCompile>

Просмотреть файл

@ -120,7 +120,6 @@ namespace BatchEncoderCoreUnitTests
public:
bool ReadLoop(IWorkerContext* ctx, IPipe* Stdin)
{
return true;
}
};

Просмотреть файл

@ -10,12 +10,16 @@ namespace BatchEncoderCoreUnitTests
TEST_CLASS(CFileToPipeReader_Tests)
{
public:
TEST_METHOD(CFileToPipeWriter_Constructor)
TEST_METHOD(CFileToPipeReader_Constructor)
{
#pragma warning(push)
#pragma warning(disable:4101)
worker::CFileToPipeReader m_Reader;
#pragma warning(pop)
}
TEST_METHOD(CFileToPipeReader_ReadLoop)
{
}
};
}

Просмотреть файл

@ -17,5 +17,13 @@ namespace BatchEncoderCoreUnitTests
worker::CLuaOutputParser m_Parser;
#pragma warning(pop)
}
TEST_METHOD(CLuaOutputParser_Open)
{
}
TEST_METHOD(CLuaOutputParser_Parse)
{
}
};
}

Просмотреть файл

@ -17,5 +17,17 @@ namespace BatchEncoderCoreUnitTests
worker::CLuaProgess m_Progess;
#pragma warning(pop)
}
TEST_METHOD(CLuaProgess_Open)
{
}
TEST_METHOD(CLuaProgess_Init)
{
}
TEST_METHOD(CLuaProgess_GetProgress)
{
}
};
}

Просмотреть файл

@ -1,21 +0,0 @@
// Copyright (c) Wiesław Šoltés. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
#include "stdafx.h"
using namespace Microsoft::VisualStudio::CppUnitTestFramework;
namespace BatchEncoderCoreUnitTests
{
TEST_CLASS(IOutputParser_Tests)
{
public:
TEST_METHOD(IOutputParser_Constructor)
{
#pragma warning(push)
#pragma warning(disable:4101)
TestOutputParser m_Parser;
#pragma warning(pop)
}
};
}

Просмотреть файл

@ -17,5 +17,9 @@ namespace BatchEncoderCoreUnitTests
worker::CPipeToFileWriter m_Writer;
#pragma warning(pop)
}
TEST_METHOD(CPipeToFileWriter_WriteLoop)
{
}
};
}

Просмотреть файл

@ -17,5 +17,9 @@ namespace BatchEncoderCoreUnitTests
worker::CPipeToStringWriter m_Writer;
#pragma warning(pop)
}
TEST_METHOD(CPipeToStringWriter_WriteLoop)
{
}
};
}

Просмотреть файл

@ -17,5 +17,9 @@ namespace BatchEncoderCoreUnitTests
worker::CToolDownloader m_Downloader;
#pragma warning(pop)
}
TEST_METHOD(CToolDownloader_Download)
{
}
};
}

Просмотреть файл

@ -7,15 +7,371 @@ using namespace Microsoft::VisualStudio::CppUnitTestFramework;
namespace BatchEncoderCoreUnitTests
{
TEST_CLASS(IWorkerContext_Tests)
TEST_CLASS(TestDownloader_Tests)
{
public:
TEST_METHOD(IWorkerContext_Constructor)
TEST_METHOD(TestDownloader_Constructor)
{
#pragma warning(push)
#pragma warning(disable:4101)
TestDownloader m_Downloader;
#pragma warning(pop)
}
TEST_METHOD(TestDownloader_Download)
{
}
};
TEST_CLASS(TestProcess_Tests)
{
public:
TEST_METHOD(TestProcess_Constructor)
{
#pragma warning(push)
#pragma warning(disable:4101)
TestProcess m_Process;
#pragma warning(pop)
}
TEST_METHOD(TestProcess_ConnectStdInput)
{
}
TEST_METHOD(TestProcess_ConnectStdOutput)
{
}
TEST_METHOD(TestProcess_ConnectStdError)
{
}
TEST_METHOD(TestProcess_Start)
{
}
TEST_METHOD(TestProcess_Wait)
{
}
TEST_METHOD(TestProcess_Wait_timeout)
{
}
TEST_METHOD(TestProcess_Terminate)
{
}
TEST_METHOD(TestProcess_Close)
{
}
TEST_METHOD(TestProcess_Stop)
{
}
TEST_METHOD(TestProcess_StdinHandle)
{
}
TEST_METHOD(TestProcess_StdoutHandle)
{
}
TEST_METHOD(TestProcess_StderrHandle)
{
}
};
TEST_CLASS(TestPipe_Tests)
{
public:
TEST_METHOD(TestPipe_Constructor)
{
#pragma warning(push)
#pragma warning(disable:4101)
TestPipe m_Pipe;
#pragma warning(pop)
}
TEST_METHOD(TestPipe_Create)
{
}
TEST_METHOD(TestPipe_CloseRead)
{
}
TEST_METHOD(TestPipe_CloseWrite)
{
}
TEST_METHOD(TestPipe_InheritRead)
{
}
TEST_METHOD(TestPipe_InheritWrite)
{
}
TEST_METHOD(TestPipe_DuplicateRead)
{
}
TEST_METHOD(TestPipe_DuplicateWrite)
{
}
TEST_METHOD(TestPipe_ReadHandle)
{
}
TEST_METHOD(TestPipe_WriteHandle)
{
}
};
TEST_CLASS(TestPipeToFileWriter_Tests)
{
public:
TEST_METHOD(TestPipeToFileWriter_Constructor)
{
#pragma warning(push)
#pragma warning(disable:4101)
TestPipeToFileWriter m_Writer;
#pragma warning(pop)
}
TEST_METHOD(TestPipeToFileWriter_WriteLoop)
{
}
};
TEST_CLASS(TestFileToPipeReader_Tests)
{
public:
TEST_METHOD(TestFileToPipeReader_Constructor)
{
#pragma warning(push)
#pragma warning(disable:4101)
TestFileToPipeReader m_Reader;
#pragma warning(pop)
}
TEST_METHOD(TestFileToPipeReader_ReadLoop)
{
}
};
TEST_CLASS(TestOutputParser_Tests)
{
public:
TEST_METHOD(TestOutputParser_Constructor)
{
#pragma warning(push)
#pragma warning(disable:4101)
TestOutputParser m_Parser;
#pragma warning(pop)
}
TEST_METHOD(TestOutputParser_Open)
{
}
TEST_METHOD(TestOutputParser_Parse)
{
}
};
TEST_CLASS(TestPipeToStringWriter_Tests)
{
public:
TEST_METHOD(TestPipeToStringWriter_Constructor)
{
#pragma warning(push)
#pragma warning(disable:4101)
TestPipeToStringWriter m_Writer;
#pragma warning(pop)
}
TEST_METHOD(TestPipeToStringWriter_WriteLoop)
{
}
};
TEST_CLASS(TestFileSystem_Tests)
{
public:
TEST_METHOD(TestFileSystem_Constructor)
{
#pragma warning(push)
#pragma warning(disable:4101)
TestFileSystem m_FileSystem
#pragma warning(pop)
}
TEST_METHOD(TestFileSystem_GenerateUuidString)
{
}
TEST_METHOD(TestFileSystem_CombinePath)
{
}
TEST_METHOD(TestFileSystem_GetFileName)
{
}
TEST_METHOD(TestFileSystem_GetFilePath)
{
}
TEST_METHOD(TestFileSystem_GetFileExtension)
{
}
TEST_METHOD(TestFileSystem_GetOnlyFileName)
{
}
TEST_METHOD(TestFileSystem_GetFileSize64_handle)
{
}
TEST_METHOD(TestFileSystem_GetFileSize64_filename)
{
}
TEST_METHOD(TestFileSystem_GetFileSizeInt64)
{
}
TEST_METHOD(TestFileSystem_GetExeFilePath)
{
}
TEST_METHOD(TestFileSystem_GetSettingsFilePath)
{
}
TEST_METHOD(TestFileSystem_GetFullPathName_)
{
}
TEST_METHOD(TestFileSystem_FileExists)
{
}
TEST_METHOD(TestFileSystem_PathFileExists_)
{
}
TEST_METHOD(TestFileSystem_DeleteFile_)
{
}
TEST_METHOD(TestFileSystem_CreateDirectory_)
{
}
TEST_METHOD(TestFileSystem_GetCurrentDirectory_)
{
}
TEST_METHOD(TestFileSystem_SetCurrentDirectory_)
{
}
TEST_METHOD(TestFileSystem_DirectoryExists)
{
}
TEST_METHOD(TestFileSystem_MakeFullPath)
{
}
TEST_METHOD(TestFileSystem_FindFiles_pattern)
{
}
TEST_METHOD(TestFileSystem_FindFiles_path)
{
}
};
TEST_CLASS(TestWorkerFactory_Tests)
{
public:
TEST_METHOD(TestWorkerFactory_Constructor)
{
#pragma warning(push)
#pragma warning(disable:4101)
TestWorkerFactory m_Factory;
#pragma warning(pop)
}
TEST_METHOD(TestWorkerFactory_CreateDownloaderPtr)
{
}
TEST_METHOD(TestWorkerFactory_CreateProcessPtr)
{
}
TEST_METHOD(TestWorkerFactory_CreatePipePtr)
{
}
TEST_METHOD(TestWorkerFactory_CreateFileReaderPtr)
{
}
TEST_METHOD(TestWorkerFactory_CreateFileWriterPtr)
{
}
TEST_METHOD(TestWorkerFactory_CreateOutputParserPtr)
{
}
TEST_METHOD(TestWorkerFactory_CreateStringWriterPtr)
{
}
};
TEST_CLASS(TestWorkerContext_Tests)
{
public:
TEST_METHOD(TestWorkerContext_Constructor)
{
TestWorkerContext ctx;
Assert::IsTrue(ctx.bDone);
Assert::IsFalse(ctx.bRunning);
Assert::IsNull(ctx.pConfig);
}
TEST_METHOD(TestWorkerContext_GetString)
{
}
TEST_METHOD(TestWorkerContext_Start)
{
}
TEST_METHOD(TestWorkerContext_Stop)
{
}
TEST_METHOD(TestWorkerContext_ItemProgress)
{
}
TEST_METHOD(TestWorkerContext_ItemStatus)
{
}
TEST_METHOD(TestWorkerContext_TotalProgress)
{
}
};
}

Просмотреть файл

@ -55,6 +55,42 @@ namespace BatchEncoderCoreUnitTests
ctx.nLastItemId = -1;
}
public:
TEST_METHOD(CWorker_ConvertUsingConsole)
{
}
TEST_METHOD(CWorker_ConvertUsingPipes)
{
}
TEST_METHOD(CWorker_ConvertUsingPipesOnly)
{
}
TEST_METHOD(CWorker_Transcode)
{
}
TEST_METHOD(CWorker_Decode)
{
}
TEST_METHOD(CWorker_Encode)
{
}
TEST_METHOD(CWorker_ConvertItem)
{
}
TEST_METHOD(CWorker_ConvertLoop)
{
}
TEST_METHOD(CWorker_Convert_Item)
{
}
TEST_METHOD(CWorker_Convert_Items_Empty)
{
config::CConfig m_Config;