Skip to content

Commit 39e6e98

Browse files
committed
AppVoyer Script & testing cmake function name update & Work on testing helper module
1 parent 359418d commit 39e6e98

29 files changed

Lines changed: 111 additions & 65 deletions

CMake/Module.cmake

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,6 @@ function (vcov_module_add_dependencies module)
7878
target_include_directories(${module} PUBLIC ${dep_includes})
7979
endif()
8080
endforeach()
81-
8281
if(_vcov_private_deps)
8382
target_link_libraries(${module} PRIVATE ${_vcov_private_deps})
8483
endif()
@@ -88,28 +87,28 @@ function (vcov_module_add_dependencies module)
8887
endfunction()
8988

9089
#[==[.rst:
91-
.. cmake:command:: vcov_add_test
90+
.. cmake:command:: vcov_module_add_test
9291
9392
.. code-block:: cmake
9493
95-
vcov_add_test(<name>)
94+
vcov_module_add_test(<name>)
9695
#]==]
97-
function (vcov_add_test module)
96+
function (vcov_module_add_test module)
9897
enable_testing()
9998
add_subdirectory(Testing)
10099
endfunction()
101100

102101
#[==[.rst:
103-
.. cmake:command:: vcov_add_test_sources
102+
.. cmake:command:: vcov_module_add_test_sources
104103
105104
.. code-block:: cmake
106105
107-
vcov_add_test_sources(<name>
106+
vcov_module_add_test_sources(<name>
108107
SOURCES [<source>...]
109108
DEPENDENCIES [<name>...]
110109
)
111110
#]==]
112-
function (vcov_add_test_sources module)
111+
function (vcov_module_add_test_sources module)
113112
cmake_parse_arguments(PARSE_ARGV 1 _vcov "" "" "SOURCES;DEPENDENCIES")
114113
if(NOT _vcov_SOURCES)
115114
message(FATAL_ERROR "No test sources provided for module ${module}")

Common/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,4 +32,4 @@ set(headers
3232
CommonExport.h
3333
)
3434
vcov_module_add_module(Common CLASSES ${classes} HEADERS ${headers})
35-
vcov_add_test(Common)
35+
vcov_module_add_test(Common)

Common/Testing/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# vcov_add_test_sources(Common
1+
# vcov_module_add_test_sources(Common
22
# SOURCES
33
# stdafx.cpp
44
# ToolTest.cpp

Console/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ vcov_module_add_dependencies(Console
2222
Binary
2323
Html
2424
)
25-
vcov_add_test(Console)
25+
vcov_module_add_test(Console)
2626

2727
add_executable(vcov main.cpp)
2828
target_link_libraries(vcov PRIVATE Console

Core/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,4 @@ vcov_module_add_dependencies(Core
3333
DEPENDENCIES
3434
Common
3535
)
36-
vcov_add_test(Core)
36+
vcov_module_add_test(Core)

Coverage/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,4 +32,4 @@ vcov_module_add_dependencies(Coverage
3232
Export
3333
Option
3434
)
35-
vcov_add_test(Coverage)
35+
vcov_module_add_test(Coverage)

Utilities/Testing/CoverageDataComparer.cpp renamed to Coverage/CoverageDataComparer.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,11 @@
1515
// along with this program. If not, see <http://www.gnu.org/licenses/>.
1616

1717
#include "stdafx.h"
18-
1918
#include "CoverageDataComparer.hpp"
2019
#include "Plugins/Exporter/CoverageData.hpp"
2120
#include "Plugin/Exporter/ModuleCoverage.hpp"
2221
#include "Plugin/Exporter/FileCoverage.hpp"
2322
#include "Plugin/Exporter/LineCoverage.hpp"
24-
2523
#include "Container.hpp"
2624

2725
namespace TestHelper

Utilities/Testing/CoverageDataComparer.hpp renamed to Coverage/CoverageDataComparer.hpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,18 +16,19 @@
1616

1717
#pragma once
1818

19-
#include "TestHelperExport.hpp"
19+
#include "TestingExport.hpp"
2020
#include <memory>
21+
#include <vector>
2122

2223
namespace Plugin
2324
{
2425
class CoverageData;
2526
class ModuleCoverage;
2627
}
2728

28-
namespace TestHelper
29+
namespace Testing
2930
{
30-
class TEST_HELPER_DLL CoverageDataComparer
31+
class VCOV_TESTINGEXPORT_DLL CoverageDataComparer
3132
{
3233
public:
3334
CoverageDataComparer() = default;

Export/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@ set(headers
1919
stdafx.h
2020
)
2121
vcov_module_add_module(Export CLASSES ${classes} HEADERS ${headers})
22-
vcov_add_test(Export)
22+
vcov_module_add_test(Export)

Export/Testing/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# vcov_add_test_sources(Export
1+
# vcov_module_add_test_sources(Export
22
# SOURCES
33
# BinaryExporterTest.cpp
44
# )

0 commit comments

Comments
 (0)