Merge lp:unity-scopes-api/staging into lp:unity-scopes-api
- staging
- Merge into trunk
Proposed by
Marcus Tomlinson
Status: | Approved |
---|---|
Approved by: | Michi Henning |
Approved revision: | 336 |
Proposed branch: | lp:unity-scopes-api/staging |
Merge into: | lp:unity-scopes-api |
Diff against target: |
3526 lines (+653/-371) 115 files modified
HACKING (+4/-4) debian/changelog (+8/-0) debian/control (+4/-117) debian/control.in (+2/-0) include/unity/scopes/internal/RegistryObject.h (+2/-1) include/unity/scopes/testing/MockObject.h (+3/-0) include/unity/scopes/testing/MockPreviewReply.h (+3/-0) include/unity/scopes/testing/MockQueryCtrl.h (+3/-0) include/unity/scopes/testing/MockRegistry.h (+3/-0) include/unity/scopes/testing/MockScope.h (+3/-0) include/unity/scopes/testing/MockSearchReply.h (+3/-0) include/unity/scopes/testing/TypedScopeFixture.h (+3/-0) scoperegistry/scoperegistry.cpp (+7/-0) src/scopes/internal/RegistryObject.cpp (+3/-3) test/gtest/CMakeLists.txt (+1/-18) test/gtest/scopes/Activation/Activation_test.cpp (+5/-1) test/gtest/scopes/ActivationResponse/ActivationResponse_test.cpp (+6/-2) test/gtest/scopes/Aggregation/ChildScopes_test.cpp (+13/-9) test/gtest/scopes/Aggregation/Keywords_test.cpp (+10/-6) test/gtest/scopes/Aggregation/LoopDetection_test.cpp (+21/-18) test/gtest/scopes/Annotation/Annotation_test.cpp (+4/-0) test/gtest/scopes/CannedQuery/CannedQuery_test.cpp (+5/-1) test/gtest/scopes/CategorisedResult/CategorisedResult_test.cpp (+4/-0) test/gtest/scopes/Category/Category_test.cpp (+3/-0) test/gtest/scopes/CategoryRenderer/CategoryRenderer_test.cpp (+4/-0) test/gtest/scopes/ColumnLayout/ColumnLayout_test.cpp (+4/-0) test/gtest/scopes/DateTimePickerFilter/DateTimePickerFilter_test.cpp (+4/-0) test/gtest/scopes/Department/Department_test.cpp (+4/-0) test/gtest/scopes/Filters/Filters_test.cpp (+5/-1) test/gtest/scopes/IdleShutdown/IdleShutdown_test.cpp (+4/-0) test/gtest/scopes/Invocation/Invocation_test.cpp (+3/-0) test/gtest/scopes/Location/Location_test.cpp (+5/-1) test/gtest/scopes/OnlineAccountClient/OnlineAccountClient_test.cpp (+8/-4) test/gtest/scopes/OptionSelectorFilter/OptionSelectorFilter_test.cpp (+5/-0) test/gtest/scopes/PreviewWidget/PreviewWidget_test.cpp (+4/-0) test/gtest/scopes/QueryMetadata/QueryMetadata_test.cpp (+5/-1) test/gtest/scopes/RadioButtonsFilter/RadioButtonsFilter_test.cpp (+4/-0) test/gtest/scopes/RangeInputFilter/RangeInputFilter_test.cpp (+4/-0) test/gtest/scopes/RatingFilter/RatingFilter_test.cpp (+5/-0) test/gtest/scopes/Registry/Registry_test.cpp (+33/-16) test/gtest/scopes/ReplyReaper/NoReplyScope.cpp (+3/-0) test/gtest/scopes/ReplyReaper/ReplyReaper_test.cpp (+4/-0) test/gtest/scopes/ResultCache/ResultCache_test.cpp (+39/-34) test/gtest/scopes/Runtime/PusherScope.cpp (+3/-0) test/gtest/scopes/Runtime/Runtime_test.cpp (+5/-2) test/gtest/scopes/Runtime/SlowCreateScope.cpp (+3/-0) test/gtest/scopes/Runtime/TestScope.cpp (+4/-0) test/gtest/scopes/ScopeBase/ScopeBase_test.cpp (+3/-0) test/gtest/scopes/ScopeExceptions/ScopeExceptions_test.cpp (+3/-0) test/gtest/scopes/StandAloneScope/StandAloneScope_test.cpp (+3/-0) test/gtest/scopes/StripLocation/StripLocation_test.cpp (+3/-0) test/gtest/scopes/SwitchFilter/SwitchFilter_test.cpp (+4/-0) test/gtest/scopes/ThrowingClient/ThrowingClient_test.cpp (+12/-9) test/gtest/scopes/ThrowingScope/ThrowingScope_test.cpp (+14/-11) test/gtest/scopes/ValueSliderFilter/ValueSliderFilter_test.cpp (+6/-2) test/gtest/scopes/Variant/Variant_test.cpp (+5/-2) test/gtest/scopes/VariantBuilder/VariantBuilder_test.cpp (+5/-1) test/gtest/scopes/Version/Version_test.cpp (+3/-0) test/gtest/scopes/internal/CategoryRegistry/CategoryRegistry_test.cpp (+3/-0) test/gtest/scopes/internal/ConfigBase/ConfigBase_test.cpp (+3/-0) test/gtest/scopes/internal/DynamicLoader/DynamicLoader_test.cpp (+3/-0) test/gtest/scopes/internal/IniSettingsSchema/IniSettingsSchema_test.cpp (+9/-6) test/gtest/scopes/internal/JsonNode/JsonNode_test.cpp (+4/-0) test/gtest/scopes/internal/JsonSettingsSchema/JsonSettingsSchema_test.cpp (+7/-4) test/gtest/scopes/internal/Logger/Logger_test.cpp (+5/-0) test/gtest/scopes/internal/MiddlewareFactory/MiddlewareFactory_test.cpp (+3/-0) test/gtest/scopes/internal/Reaper/Reaper_test.cpp (+17/-14) test/gtest/scopes/internal/RegistryConfig/RegistryConfig_test.cpp (+3/-0) test/gtest/scopes/internal/RegistryObject/RegistryObject_test.cpp (+3/-1) test/gtest/scopes/internal/ResultReplyObject/ResultReplyObject_test.cpp (+4/-0) test/gtest/scopes/internal/RuntimeConfig/RuntimeConfig_test.cpp (+3/-0) test/gtest/scopes/internal/RuntimeImpl/RuntimeImpl_test.cpp (+4/-0) test/gtest/scopes/internal/ScopeConfig/ScopeConfig_test.cpp (+9/-6) test/gtest/scopes/internal/ScopeLoader/ScopeLoader_test.cpp (+3/-0) test/gtest/scopes/internal/ScopeMetadataImpl/ScopeMetadataImpl_test.cpp (+5/-2) test/gtest/scopes/internal/SettingsDB/SettingsDB_test.cpp (+25/-21) test/gtest/scopes/internal/ThreadPool/ThreadPool_test.cpp (+4/-0) test/gtest/scopes/internal/ThreadSafeQueue/ThreadSafeQueue_test.cpp (+3/-0) test/gtest/scopes/internal/UniqueID/UniqueID_test.cpp (+3/-0) test/gtest/scopes/internal/Utils/Utils_test.cpp (+21/-5) test/gtest/scopes/internal/gobj_ptr/gobj_ptr_test.cpp (+12/-8) test/gtest/scopes/internal/safe_strerror/safe_strerror_test.cpp (+4/-0) test/gtest/scopes/internal/smartscopes/HttpClient/HttpClient_test.cpp (+4/-0) test/gtest/scopes/internal/smartscopes/SSConfig/SSConfig_test.cpp (+3/-0) test/gtest/scopes/internal/smartscopes/SmartScopesClient/SmartScopesClient_test.cpp (+24/-20) test/gtest/scopes/internal/smartscopes/smartscopesproxy/smartscopesproxy_test.cpp (+11/-7) test/gtest/scopes/internal/zmq_middleware/ConnectionPool/ConnectionPool_test.cpp (+3/-0) test/gtest/scopes/internal/zmq_middleware/ObjectAdapter/ObjectAdapter_test.cpp (+4/-0) test/gtest/scopes/internal/zmq_middleware/PubSub/PubSub_test.cpp (+4/-0) test/gtest/scopes/internal/zmq_middleware/RegistryI/RegistryI_test.cpp (+4/-1) test/gtest/scopes/internal/zmq_middleware/ServantBase/ServantBase_test.cpp (+3/-0) test/gtest/scopes/internal/zmq_middleware/StopPublisher/StopPublisher_test.cpp (+3/-0) test/gtest/scopes/internal/zmq_middleware/Util/Util_test.cpp (+4/-0) test/gtest/scopes/internal/zmq_middleware/VariantConverter/VariantConverter_test.cpp (+5/-1) test/gtest/scopes/internal/zmq_middleware/ZmqMiddleware/ZmqMiddleware_test.cpp (+3/-0) test/gtest/scopes/qt/JsonAsyncReader/JsonAsyncReader_test.cpp (+5/-1) test/gtest/scopes/qt/XmlAsyncReader/XmlAsyncReader_test.cpp (+3/-0) test/gtest/scopes/qt/qt-bindings/QActionMetadata_test.cpp (+3/-0) test/gtest/scopes/qt/qt-bindings/QCannedQuery_test.cpp (+4/-1) test/gtest/scopes/qt/qt-bindings/QCategorisedResult_test.cpp (+3/-0) test/gtest/scopes/qt/qt-bindings/QColumnLayout_test.cpp (+5/-2) test/gtest/scopes/qt/qt-bindings/QDepartment_test.cpp (+4/-1) test/gtest/scopes/qt/qt-bindings/QPreviewQueryBaseAPI_test.cpp (+3/-1) test/gtest/scopes/qt/qt-bindings/QPreviewWidget_test.cpp (+3/-0) test/gtest/scopes/qt/qt-bindings/QScopeBaseAPIImpl_test.cpp (+3/-1) test/gtest/scopes/qt/qt-bindings/QScopeCreation_test.cpp (+4/-0) test/gtest/scopes/qt/qt-bindings/QSearchMetadata_test.cpp (+3/-0) test/gtest/scopes/qt/qt-bindings/QSearchQueryBaseAPI_test.cpp (+3/-1) test/gtest/scopes/qt/qt-bindings/QUtils_test.cpp (+4/-1) test/gtest/scopes/qt/qt-bindings/QVariantBuilder_test.cpp (+3/-0) test/gtest/scopes/stress/scopes-stress.cpp (+6/-2) test/gtest/scopes/testing/IsolatedScope/IsolatedScope_test.cpp (+3/-0) test/gtest/scopes/testing/IsolatedScopeBenchmark/IsolatedScopeBenchmark_test.cpp (+3/-0) test/gtest/scopes/testing/Statistics/Statistics_test.cpp (+3/-0) test/gtest/scopes/utility/BufferedResultForwarder/BufferedResultForwarder_test.cpp (+4/-0) |
To merge this branch: | bzr merge lp:unity-scopes-api/staging |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Unity Team | Pending | ||
Review via email: mp+314795@code.launchpad.net |
Commit message
Fixed lots of compiler warnings.
Fix for bug #1656042 (cmake changes for new gtest).
Description of the change
Fixed lots of compiler warnings.
Fix for bug #1656042 (cmake changes for new gtest).
To post a comment you must log in.
Unmerged revisions
- 336. By Marcus Tomlinson
-
Updated changelog.
- 335. By Marcus Tomlinson
-
Merge devel
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'HACKING' | |||
2 | --- HACKING 2016-09-09 06:57:47 +0000 | |||
3 | +++ HACKING 2017-01-16 06:43:13 +0000 | |||
4 | @@ -205,13 +205,13 @@ | |||
5 | 205 | 205 | ||
6 | 206 | - QT-VERSION | 206 | - QT-VERSION |
7 | 207 | 207 | ||
9 | 208 | The full version number parts for libunity-scopes-qt. | 208 | The full version number for libunity-scopes-qt. |
10 | 209 | 209 | ||
11 | 210 | - *If* the soname changes, you need to add the outdated | 210 | - *If* the soname changes, you need to add the outdated |
12 | 211 | versions to the "Replaces:" and "Conflicts:" entries | 211 | versions to the "Replaces:" and "Conflicts:" entries |
16 | 212 | in control and control.in. (You need an extra | 212 | in control.in. (You need an extra entry for each Vivid and |
17 | 213 | entry for each Vivid and Wily/Xenial andlater. See | 213 | Wily/Xenial and later.) |
18 | 214 | bileto_pre_release_hook for the sed scripts that append a | 214 | See bileto_pre_release_hook for the sed scripts that append a |
19 | 215 | line to the stanza if the soname is changed. This also may apply | 215 | line to the stanza if the soname is changed. This also may apply |
20 | 216 | if the soname of the Qt library changes, in which case | 216 | if the soname of the Qt library changes, in which case |
21 | 217 | bileto_pre_release_hook needs a corresponding update. | 217 | bileto_pre_release_hook needs a corresponding update. |
22 | 218 | 218 | ||
23 | === modified file 'debian/changelog' | |||
24 | --- debian/changelog 2016-11-15 06:09:04 +0000 | |||
25 | +++ debian/changelog 2017-01-16 06:43:13 +0000 | |||
26 | @@ -1,3 +1,11 @@ | |||
27 | 1 | unity-scopes-api (1.0.8ubuntu1) UNRELEASED; urgency=medium | ||
28 | 2 | |||
29 | 3 | * Create $HOME/.local/share/applications if it does not exist. lp:1645798 | ||
30 | 4 | * Fixed lots of compiler warnings. | ||
31 | 5 | * Changed cmake files to work with new gtest. | ||
32 | 6 | |||
33 | 7 | -- Michi Henning <michi.henning@canonical.com> Mon, 16 Jan 2017 12:30:39 +1000 | ||
34 | 8 | |||
35 | 1 | unity-scopes-api (1.0.7+17.04.20161115-0ubuntu1) zesty; urgency=medium | 9 | unity-scopes-api (1.0.7+17.04.20161115-0ubuntu1) zesty; urgency=medium |
36 | 2 | 10 | ||
37 | 3 | * Be stricter on user-configurable idle timeout (1s to 5min). | 11 | * Be stricter on user-configurable idle timeout (1s to 5min). |
38 | 4 | 12 | ||
39 | === modified file 'debian/control' | |||
40 | --- debian/control 2016-11-15 06:09:04 +0000 | |||
41 | +++ debian/control 2017-01-16 06:43:13 +0000 | |||
42 | @@ -4,123 +4,10 @@ | |||
43 | 4 | # This file is regenerated automatically by bileto. | 4 | # This file is regenerated automatically by bileto. |
44 | 5 | # | 5 | # |
45 | 6 | Source: unity-scopes-api | 6 | Source: unity-scopes-api |
92 | 7 | Priority: optional | 7 | |
93 | 8 | Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com> | 8 | # DO NOT EDIT THIS FILE. WE REALLY MEAN IT! |
48 | 9 | Build-Depends: abigail-tools <!nocheck> | libabigail-tools <!nocheck>, | ||
49 | 10 | binutils:native, | ||
50 | 11 | capnproto, | ||
51 | 12 | click-dev (>= 0.2.2), | ||
52 | 13 | cmake, | ||
53 | 14 | dbus-test-runner, | ||
54 | 15 | debhelper (>= 9), | ||
55 | 16 | devscripts, | ||
56 | 17 | doxygen, | ||
57 | 18 | exuberant-ctags, | ||
58 | 19 | google-mock, | ||
59 | 20 | graphviz, | ||
60 | 21 | libaccounts-glib-dev, | ||
61 | 22 | libapparmor-dev, | ||
62 | 23 | libboost-filesystem-dev, | ||
63 | 24 | libboost-regex-dev, | ||
64 | 25 | libboost-serialization-dev, | ||
65 | 26 | libboost-thread-dev, | ||
66 | 27 | libcapnp-dev (>= 0.4.0), | ||
67 | 28 | libdbustest1-dev, | ||
68 | 29 | libjson-glib-dev, | ||
69 | 30 | liblttng-ust-dev, | ||
70 | 31 | libnet-cpp-dev (>= 1.2.0), | ||
71 | 32 | libprocess-cpp-dev (>= 1.0.1), | ||
72 | 33 | libsignon-glib-dev, | ||
73 | 34 | libunity-api-dev (>= 7.80.7~), | ||
74 | 35 | libzmq3-dev, | ||
75 | 36 | libzmqpp-dev, | ||
76 | 37 | lsb-release, | ||
77 | 38 | lttng-tools, | ||
78 | 39 | pkg-config, | ||
79 | 40 | python3 <!nocheck>, | ||
80 | 41 | python3-dbusmock <!nocheck>, | ||
81 | 42 | python-tornado <!nocheck>, | ||
82 | 43 | valgrind, | ||
83 | 44 | Standards-Version: 3.9.6 | ||
84 | 45 | XS-Testsuite: autopkgtest | ||
85 | 46 | Section: libs | ||
86 | 47 | Homepage: https://launchpad.net/unity-scopes-api | ||
87 | 48 | # if you don't have have commit access to this branch but would like to upload | ||
88 | 49 | # directly to Ubuntu, don't worry: your changes will be merged back into the | ||
89 | 50 | # upstream branch | ||
90 | 51 | Vcs-Bzr: lp:unity-scopes-api | ||
91 | 52 | Vcs-Browser: https://code.launchpad.net/unity-scopes-api | ||
94 | 53 | 9 | ||
95 | 54 | Package: libunity-scopes1.0 | 10 | Package: libunity-scopes1.0 |
96 | 55 | Architecture: any | 11 | Architecture: any |
168 | 56 | Multi-Arch: same | 12 | Description: DO NOT EDIT THIS FILE, IT IS GENERATED FROM control.in |
169 | 57 | Pre-Depends: ${misc:Pre-Depends}, | 13 | DO NOT EDIT THIS FILE |
99 | 58 | Depends: ${misc:Depends}, | ||
100 | 59 | ${shlibs:Depends}, | ||
101 | 60 | Replaces: libunity-scopes0, | ||
102 | 61 | libunity-scopes3, | ||
103 | 62 | libunity-scopes1, | ||
104 | 63 | libunity-scopes2, | ||
105 | 64 | Conflicts: libunity-scopes0, | ||
106 | 65 | libunity-scopes3, | ||
107 | 66 | libunity-scopes1, | ||
108 | 67 | libunity-scopes2, | ||
109 | 68 | Description: API for Unity scopes integration | ||
110 | 69 | Library to integrate scopes with the Unity shell | ||
111 | 70 | |||
112 | 71 | Package: libunity-scopes-dev | ||
113 | 72 | Section: libdevel | ||
114 | 73 | Architecture: any | ||
115 | 74 | Multi-Arch: same | ||
116 | 75 | Depends: libproperties-cpp-dev, | ||
117 | 76 | libunity-api-dev, | ||
118 | 77 | libunity-scopes1.0 (= ${binary:Version}), | ||
119 | 78 | ${misc:Depends}, | ||
120 | 79 | Description: Header files for Unity scopes API | ||
121 | 80 | Library to integrate scopes with the Unity shell (dev files) | ||
122 | 81 | |||
123 | 82 | Package: libunity-scopes-cli | ||
124 | 83 | Section: devel | ||
125 | 84 | Architecture: any | ||
126 | 85 | Multi-Arch: foreign | ||
127 | 86 | Depends: libunity-scopes1.0 (= ${binary:Version}), | ||
128 | 87 | ${misc:Depends}, | ||
129 | 88 | ${shlibs:Depends}, | ||
130 | 89 | Description: Client utility for Unity scopes API | ||
131 | 90 | Commandline client utility for querying Unity scopes, useful for testing. | ||
132 | 91 | |||
133 | 92 | Package: libunity-scopes-doc | ||
134 | 93 | Section: doc | ||
135 | 94 | Architecture: all | ||
136 | 95 | Multi-Arch: foreign | ||
137 | 96 | Depends: ${misc:Depends}, | ||
138 | 97 | Description: Documentation for Unity scopes API | ||
139 | 98 | Library to integrate scopes with the Unity shell (documentation) | ||
140 | 99 | |||
141 | 100 | Package: libunity-scopes-qt0.2 | ||
142 | 101 | Architecture: any | ||
143 | 102 | Multi-Arch: same | ||
144 | 103 | Pre-Depends: ${misc:Pre-Depends}, | ||
145 | 104 | Depends: ${misc:Depends}, | ||
146 | 105 | ${shlibs:Depends}, | ||
147 | 106 | Description: Qt library for Unity scopes API | ||
148 | 107 | Library that integrates classes based on Qt for convenience | ||
149 | 108 | |||
150 | 109 | Package: libunity-scopes-qt-dev | ||
151 | 110 | Section: libdevel | ||
152 | 111 | Architecture: any | ||
153 | 112 | Multi-Arch: same | ||
154 | 113 | Depends: libunity-scopes-dev (= ${binary:Version}), | ||
155 | 114 | libunity-scopes-qt0.2 (= ${binary:Version}), | ||
156 | 115 | libnet-cpp-dev (>=1.2.0), | ||
157 | 116 | ${misc:Depends}, | ||
158 | 117 | Description: Header files for Qt library for Unity scopes API | ||
159 | 118 | Library that integrates classes based on Qt for convenience (dev files) | ||
160 | 119 | |||
161 | 120 | Package: libunity-scopes-qt-doc | ||
162 | 121 | Section: doc | ||
163 | 122 | Architecture: all | ||
164 | 123 | Multi-Arch: foreign | ||
165 | 124 | Depends: ${misc:Depends}, | ||
166 | 125 | Description: Documentation for Unity Qt library | ||
167 | 126 | Library that integrates classes based on Qt for convenience (documentation) | ||
170 | 127 | 14 | ||
171 | === modified file 'debian/control.in' | |||
172 | --- debian/control.in 2016-07-25 05:35:44 +0000 | |||
173 | +++ debian/control.in 2017-01-16 06:43:13 +0000 | |||
174 | @@ -6,6 +6,7 @@ | |||
175 | 6 | capnproto, | 6 | capnproto, |
176 | 7 | click-dev (>= 0.2.2), | 7 | click-dev (>= 0.2.2), |
177 | 8 | cmake, | 8 | cmake, |
178 | 9 | cmake-extras (>= 0.4), | ||
179 | 9 | dbus-test-runner, | 10 | dbus-test-runner, |
180 | 10 | debhelper (>= 9), | 11 | debhelper (>= 9), |
181 | 11 | devscripts, | 12 | devscripts, |
182 | @@ -13,6 +14,7 @@ | |||
183 | 13 | exuberant-ctags, | 14 | exuberant-ctags, |
184 | 14 | google-mock, | 15 | google-mock, |
185 | 15 | graphviz, | 16 | graphviz, |
186 | 17 | language-pack-tr, | ||
187 | 16 | libaccounts-glib-dev, | 18 | libaccounts-glib-dev, |
188 | 17 | libapparmor-dev, | 19 | libapparmor-dev, |
189 | 18 | libboost-filesystem-dev, | 20 | libboost-filesystem-dev, |
190 | 19 | 21 | ||
191 | === modified file 'include/unity/scopes/internal/RegistryObject.h' | |||
192 | --- include/unity/scopes/internal/RegistryObject.h 2016-02-22 00:19:46 +0000 | |||
193 | +++ include/unity/scopes/internal/RegistryObject.h 2017-01-16 06:43:13 +0000 | |||
194 | @@ -78,11 +78,12 @@ | |||
195 | 78 | 78 | ||
196 | 79 | StateReceiverObject::SPtr state_receiver(); | 79 | StateReceiverObject::SPtr state_receiver(); |
197 | 80 | 80 | ||
198 | 81 | static std::string desktop_files_dir(); | ||
199 | 82 | |||
200 | 81 | private: | 83 | private: |
201 | 82 | void on_process_death(core::posix::ChildProcess const& process); | 84 | void on_process_death(core::posix::ChildProcess const& process); |
202 | 83 | void on_state_received(std::string const& scope_id, StateReceiverObject::State const& state); | 85 | void on_state_received(std::string const& scope_id, StateReceiverObject::State const& state); |
203 | 84 | 86 | ||
204 | 85 | static std::string desktop_files_dir(); | ||
205 | 86 | void create_desktop_file(ScopeMetadata const& metadata); | 87 | void create_desktop_file(ScopeMetadata const& metadata); |
206 | 87 | void remove_desktop_file(std::string const& scope_id); | 88 | void remove_desktop_file(std::string const& scope_id); |
207 | 88 | 89 | ||
208 | 89 | 90 | ||
209 | === modified file 'include/unity/scopes/testing/MockObject.h' | |||
210 | --- include/unity/scopes/testing/MockObject.h 2015-04-01 11:28:32 +0000 | |||
211 | +++ include/unity/scopes/testing/MockObject.h 2017-01-16 06:43:13 +0000 | |||
212 | @@ -20,7 +20,10 @@ | |||
213 | 20 | 20 | ||
214 | 21 | #include <unity/scopes/Object.h> | 21 | #include <unity/scopes/Object.h> |
215 | 22 | 22 | ||
216 | 23 | #pragma GCC diagnostic push | ||
217 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
218 | 23 | #include <gmock/gmock.h> | 25 | #include <gmock/gmock.h> |
219 | 26 | #pragma GCC diagnostic pop | ||
220 | 24 | 27 | ||
221 | 25 | namespace unity | 28 | namespace unity |
222 | 26 | { | 29 | { |
223 | 27 | 30 | ||
224 | === modified file 'include/unity/scopes/testing/MockPreviewReply.h' | |||
225 | --- include/unity/scopes/testing/MockPreviewReply.h 2015-04-10 10:10:06 +0000 | |||
226 | +++ include/unity/scopes/testing/MockPreviewReply.h 2017-01-16 06:43:13 +0000 | |||
227 | @@ -22,7 +22,10 @@ | |||
228 | 22 | 22 | ||
229 | 23 | #include <unity/scopes/testing/MockObject.h> | 23 | #include <unity/scopes/testing/MockObject.h> |
230 | 24 | 24 | ||
231 | 25 | #pragma GCC diagnostic push | ||
232 | 26 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
233 | 25 | #include <gmock/gmock.h> | 27 | #include <gmock/gmock.h> |
234 | 28 | #pragma GCC diagnostic pop | ||
235 | 26 | 29 | ||
236 | 27 | namespace unity | 30 | namespace unity |
237 | 28 | { | 31 | { |
238 | 29 | 32 | ||
239 | === modified file 'include/unity/scopes/testing/MockQueryCtrl.h' | |||
240 | --- include/unity/scopes/testing/MockQueryCtrl.h 2014-11-03 05:31:30 +0000 | |||
241 | +++ include/unity/scopes/testing/MockQueryCtrl.h 2017-01-16 06:43:13 +0000 | |||
242 | @@ -22,7 +22,10 @@ | |||
243 | 22 | 22 | ||
244 | 23 | #include <unity/scopes/testing/MockObject.h> | 23 | #include <unity/scopes/testing/MockObject.h> |
245 | 24 | 24 | ||
246 | 25 | #pragma GCC diagnostic push | ||
247 | 26 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
248 | 25 | #include <gmock/gmock.h> | 27 | #include <gmock/gmock.h> |
249 | 28 | #pragma GCC diagnostic pop | ||
250 | 26 | 29 | ||
251 | 27 | namespace unity | 30 | namespace unity |
252 | 28 | { | 31 | { |
253 | 29 | 32 | ||
254 | === modified file 'include/unity/scopes/testing/MockRegistry.h' | |||
255 | --- include/unity/scopes/testing/MockRegistry.h 2015-02-06 00:25:05 +0000 | |||
256 | +++ include/unity/scopes/testing/MockRegistry.h 2017-01-16 06:43:13 +0000 | |||
257 | @@ -21,7 +21,10 @@ | |||
258 | 21 | #include <unity/scopes/Registry.h> | 21 | #include <unity/scopes/Registry.h> |
259 | 22 | #include <unity/scopes/testing/MockObject.h> | 22 | #include <unity/scopes/testing/MockObject.h> |
260 | 23 | 23 | ||
261 | 24 | #pragma GCC diagnostic push | ||
262 | 25 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
263 | 24 | #include <gmock/gmock.h> | 26 | #include <gmock/gmock.h> |
264 | 27 | #pragma GCC diagnostic pop | ||
265 | 25 | 28 | ||
266 | 26 | namespace unity | 29 | namespace unity |
267 | 27 | { | 30 | { |
268 | 28 | 31 | ||
269 | === modified file 'include/unity/scopes/testing/MockScope.h' | |||
270 | --- include/unity/scopes/testing/MockScope.h 2016-09-08 08:22:37 +0000 | |||
271 | +++ include/unity/scopes/testing/MockScope.h 2017-01-16 06:43:13 +0000 | |||
272 | @@ -24,7 +24,10 @@ | |||
273 | 24 | 24 | ||
274 | 25 | #include <unity/scopes/testing/MockObject.h> | 25 | #include <unity/scopes/testing/MockObject.h> |
275 | 26 | 26 | ||
276 | 27 | #pragma GCC diagnostic push | ||
277 | 28 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
278 | 27 | #include <gmock/gmock.h> | 29 | #include <gmock/gmock.h> |
279 | 30 | #pragma GCC diagnostic pop | ||
280 | 28 | 31 | ||
281 | 29 | namespace unity | 32 | namespace unity |
282 | 30 | { | 33 | { |
283 | 31 | 34 | ||
284 | === modified file 'include/unity/scopes/testing/MockSearchReply.h' | |||
285 | --- include/unity/scopes/testing/MockSearchReply.h 2016-06-14 14:19:25 +0000 | |||
286 | +++ include/unity/scopes/testing/MockSearchReply.h 2017-01-16 06:43:13 +0000 | |||
287 | @@ -24,7 +24,10 @@ | |||
288 | 24 | 24 | ||
289 | 25 | #include <unity/scopes/testing/MockObject.h> | 25 | #include <unity/scopes/testing/MockObject.h> |
290 | 26 | 26 | ||
291 | 27 | #pragma GCC diagnostic push | ||
292 | 28 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
293 | 27 | #include <gmock/gmock.h> | 29 | #include <gmock/gmock.h> |
294 | 30 | #pragma GCC diagnostic pop | ||
295 | 28 | 31 | ||
296 | 29 | namespace unity | 32 | namespace unity |
297 | 30 | { | 33 | { |
298 | 31 | 34 | ||
299 | === modified file 'include/unity/scopes/testing/TypedScopeFixture.h' | |||
300 | --- include/unity/scopes/testing/TypedScopeFixture.h 2016-03-09 04:01:35 +0000 | |||
301 | +++ include/unity/scopes/testing/TypedScopeFixture.h 2017-01-16 06:43:13 +0000 | |||
302 | @@ -22,7 +22,10 @@ | |||
303 | 22 | 22 | ||
304 | 23 | #include <unity/scopes/testing/MockRegistry.h> | 23 | #include <unity/scopes/testing/MockRegistry.h> |
305 | 24 | 24 | ||
306 | 25 | #pragma GCC diagnostic push | ||
307 | 26 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
308 | 25 | #include <gtest/gtest.h> | 27 | #include <gtest/gtest.h> |
309 | 28 | #pragma GCC diagnostic pop | ||
310 | 26 | 29 | ||
311 | 27 | #include <memory> | 30 | #include <memory> |
312 | 28 | 31 | ||
313 | 29 | 32 | ||
314 | === modified file 'scoperegistry/scoperegistry.cpp' | |||
315 | --- scoperegistry/scoperegistry.cpp 2016-04-01 06:05:09 +0000 | |||
316 | +++ scoperegistry/scoperegistry.cpp 2017-01-16 06:43:13 +0000 | |||
317 | @@ -496,6 +496,13 @@ | |||
318 | 496 | string tmp_dir = string("/run/user/") + std::to_string(geteuid()) + "/scopes/leaf-net"; | 496 | string tmp_dir = string("/run/user/") + std::to_string(geteuid()) + "/scopes/leaf-net"; |
319 | 497 | make_directories(tmp_dir, 0700); | 497 | make_directories(tmp_dir, 0700); |
320 | 498 | 498 | ||
321 | 499 | // Make sure that the directory for .desktop files exists. | ||
322 | 500 | string desktop_files_dir = RegistryObject::desktop_files_dir(); | ||
323 | 501 | if (!desktop_files_dir.empty()) | ||
324 | 502 | { | ||
325 | 503 | make_directories(desktop_files_dir, 0700); | ||
326 | 504 | } | ||
327 | 505 | |||
328 | 499 | // Collect the registry config data. | 506 | // Collect the registry config data. |
329 | 500 | 507 | ||
330 | 501 | string mw_kind; | 508 | string mw_kind; |
331 | 502 | 509 | ||
332 | === modified file 'src/scopes/internal/RegistryObject.cpp' | |||
333 | --- src/scopes/internal/RegistryObject.cpp 2016-02-22 01:29:01 +0000 | |||
334 | +++ src/scopes/internal/RegistryObject.cpp 2017-01-16 06:43:13 +0000 | |||
335 | @@ -404,13 +404,13 @@ | |||
336 | 404 | 404 | ||
337 | 405 | void RegistryObject::create_desktop_file(ScopeMetadata const& metadata) | 405 | void RegistryObject::create_desktop_file(ScopeMetadata const& metadata) |
338 | 406 | { | 406 | { |
341 | 407 | std::string desktop_file_path = desktop_files_dir(); | 407 | static std::string const desktop_files_dir = RegistryObject::desktop_files_dir(); |
342 | 408 | if (!generate_desktop_files_ || desktop_file_path.empty()) | 408 | if (!generate_desktop_files_ || desktop_files_dir.empty()) |
343 | 409 | { | 409 | { |
344 | 410 | return; | 410 | return; |
345 | 411 | } | 411 | } |
346 | 412 | 412 | ||
348 | 413 | desktop_file_path += "/" + metadata.scope_id() + ".desktop"; | 413 | std::string const desktop_file_path = desktop_files_dir + "/" + metadata.scope_id() + ".desktop"; |
349 | 414 | 414 | ||
350 | 415 | std::ofstream desktop_file(desktop_file_path.c_str()); | 415 | std::ofstream desktop_file(desktop_file_path.c_str()); |
351 | 416 | if (!desktop_file) | 416 | if (!desktop_file) |
352 | 417 | 417 | ||
353 | === modified file 'test/gtest/CMakeLists.txt' | |||
354 | --- test/gtest/CMakeLists.txt 2014-12-02 02:00:57 +0000 | |||
355 | +++ test/gtest/CMakeLists.txt 2017-01-16 06:43:13 +0000 | |||
356 | @@ -1,21 +1,4 @@ | |||
375 | 1 | if (NOT DEFINED GMOCK_ROOT) | 1 | find_package(GMock) |
358 | 2 | set(GMOCK_ROOT /usr/src/gmock) | ||
359 | 3 | endif() | ||
360 | 4 | |||
361 | 5 | add_subdirectory(${GMOCK_ROOT} gmock) | ||
362 | 6 | |||
363 | 7 | # Selectively switch off warnings about missing field initializers when building gmock and gtest | ||
364 | 8 | set_property(TARGET gmock APPEND_STRING PROPERTY COMPILE_FLAGS " -Wno-missing-field-initializers -Wno-old-style-cast") | ||
365 | 9 | set_property(TARGET gmock_main APPEND_STRING PROPERTY COMPILE_FLAGS " -Wno-missing-field-initializers -Wno-old-style-cast") | ||
366 | 10 | set_property(TARGET gtest APPEND_STRING PROPERTY COMPILE_FLAGS " -Wno-missing-field-initializers -Wno-old-style-cast") | ||
367 | 11 | |||
368 | 12 | # Make sure we always build gtest/gmock with debug info, otherwise we don't | ||
369 | 13 | # get line numbers for the code that is dragged in by the test macros. | ||
370 | 14 | set_property(TARGET gmock APPEND_STRING PROPERTY COMPILE_FLAGS " -g") | ||
371 | 15 | set_property(TARGET gmock_main APPEND_STRING PROPERTY COMPILE_FLAGS " -g") | ||
372 | 16 | set_property(TARGET gtest APPEND_STRING PROPERTY COMPILE_FLAGS " -g") | ||
373 | 17 | |||
374 | 18 | include_directories(${GMOCK_ROOT}/gtest/include) | ||
376 | 19 | 2 | ||
377 | 20 | set(LIBGTEST gtest gmock gmock_main) | 3 | set(LIBGTEST gtest gmock gmock_main) |
378 | 21 | set(TESTLIBS ${TESTLIBS} ${LIBGTEST} boost_regex) | 4 | set(TESTLIBS ${TESTLIBS} ${LIBGTEST} boost_regex) |
379 | 22 | 5 | ||
380 | === modified file 'test/gtest/scopes/Activation/Activation_test.cpp' | |||
381 | --- test/gtest/scopes/Activation/Activation_test.cpp 2015-06-08 14:05:12 +0000 | |||
382 | +++ test/gtest/scopes/Activation/Activation_test.cpp 2017-01-16 06:43:13 +0000 | |||
383 | @@ -28,10 +28,14 @@ | |||
384 | 28 | #include <unity/scopes/ActionMetadata.h> | 28 | #include <unity/scopes/ActionMetadata.h> |
385 | 29 | #include <unity/UnityExceptions.h> | 29 | #include <unity/UnityExceptions.h> |
386 | 30 | #include <functional> | 30 | #include <functional> |
387 | 31 | #include <gtest/gtest.h> | ||
388 | 32 | #include <unity/scopes/testing/Result.h> | 31 | #include <unity/scopes/testing/Result.h> |
389 | 33 | #include <TestScope.h> | 32 | #include <TestScope.h> |
390 | 34 | 33 | ||
391 | 34 | #pragma GCC diagnostic push | ||
392 | 35 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
393 | 36 | #include <gtest/gtest.h> | ||
394 | 37 | #pragma GCC diagnostic pop | ||
395 | 38 | |||
396 | 35 | using namespace unity::scopes; | 39 | using namespace unity::scopes; |
397 | 36 | using namespace unity::scopes::internal; | 40 | using namespace unity::scopes::internal; |
398 | 37 | 41 | ||
399 | 38 | 42 | ||
400 | === modified file 'test/gtest/scopes/ActivationResponse/ActivationResponse_test.cpp' | |||
401 | --- test/gtest/scopes/ActivationResponse/ActivationResponse_test.cpp 2015-07-14 15:11:48 +0000 | |||
402 | +++ test/gtest/scopes/ActivationResponse/ActivationResponse_test.cpp 2017-01-16 06:43:13 +0000 | |||
403 | @@ -22,7 +22,11 @@ | |||
404 | 22 | #include <unity/scopes/internal/ResultImpl.h> | 22 | #include <unity/scopes/internal/ResultImpl.h> |
405 | 23 | #include <unity/scopes/internal/RuntimeImpl.h> | 23 | #include <unity/scopes/internal/RuntimeImpl.h> |
406 | 24 | #include <unity/UnityExceptions.h> | 24 | #include <unity/UnityExceptions.h> |
407 | 25 | |||
408 | 26 | #pragma GCC diagnostic push | ||
409 | 27 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
410 | 25 | #include <gtest/gtest.h> | 28 | #include <gtest/gtest.h> |
411 | 29 | #pragma GCC diagnostic pop | ||
412 | 26 | 30 | ||
413 | 27 | using namespace unity::scopes; | 31 | using namespace unity::scopes; |
414 | 28 | using namespace unity::scopes::internal; | 32 | using namespace unity::scopes::internal; |
415 | @@ -107,7 +111,7 @@ | |||
416 | 107 | 111 | ||
417 | 108 | ActivationResponse resp(widgets); | 112 | ActivationResponse resp(widgets); |
418 | 109 | EXPECT_EQ(ActivationResponse::Status::UpdatePreview, resp.status()); | 113 | EXPECT_EQ(ActivationResponse::Status::UpdatePreview, resp.status()); |
420 | 110 | EXPECT_EQ(1, resp.updated_widgets().size()); | 114 | EXPECT_EQ(1u, resp.updated_widgets().size()); |
421 | 111 | EXPECT_EQ("w1", resp.updated_widgets().begin()->id()); | 115 | EXPECT_EQ("w1", resp.updated_widgets().begin()->id()); |
422 | 112 | } | 116 | } |
423 | 113 | 117 | ||
424 | @@ -170,7 +174,7 @@ | |||
425 | 170 | 174 | ||
426 | 171 | ActivationResponse resp2 = internal::ActivationResponseImpl::create(var, runtime.get()); | 175 | ActivationResponse resp2 = internal::ActivationResponseImpl::create(var, runtime.get()); |
427 | 172 | EXPECT_EQ(ActivationResponse::Status::UpdatePreview, resp2.status()); | 176 | EXPECT_EQ(ActivationResponse::Status::UpdatePreview, resp2.status()); |
429 | 173 | EXPECT_EQ(1, resp2.updated_widgets().size()); | 177 | EXPECT_EQ(1u, resp2.updated_widgets().size()); |
430 | 174 | EXPECT_EQ("w1", resp2.updated_widgets().begin()->id()); | 178 | EXPECT_EQ("w1", resp2.updated_widgets().begin()->id()); |
431 | 175 | } | 179 | } |
432 | 176 | } | 180 | } |
433 | 177 | 181 | ||
434 | === modified file 'test/gtest/scopes/Aggregation/ChildScopes_test.cpp' | |||
435 | --- test/gtest/scopes/Aggregation/ChildScopes_test.cpp 2015-12-18 09:21:53 +0000 | |||
436 | +++ test/gtest/scopes/Aggregation/ChildScopes_test.cpp 2017-01-16 06:43:13 +0000 | |||
437 | @@ -26,7 +26,11 @@ | |||
438 | 26 | 26 | ||
439 | 27 | #include <boost/filesystem/operations.hpp> | 27 | #include <boost/filesystem/operations.hpp> |
440 | 28 | #include <fstream> | 28 | #include <fstream> |
441 | 29 | |||
442 | 30 | #pragma GCC diagnostic push | ||
443 | 31 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
444 | 29 | #include <gtest/gtest.h> | 32 | #include <gtest/gtest.h> |
445 | 33 | #pragma GCC diagnostic pop | ||
446 | 30 | 34 | ||
447 | 31 | using namespace boost; | 35 | using namespace boost; |
448 | 32 | using namespace testing; | 36 | using namespace testing; |
449 | @@ -152,7 +156,7 @@ | |||
450 | 152 | 156 | ||
451 | 153 | // 1st TestScope::find_child_scopes() returns: "A,B,C" | 157 | // 1st TestScope::find_child_scopes() returns: "A,B,C" |
452 | 154 | ChildScopeList return_list = test_scope->child_scopes(); | 158 | ChildScopeList return_list = test_scope->child_scopes(); |
454 | 155 | ASSERT_EQ(3, return_list.size()); | 159 | ASSERT_EQ(3u, return_list.size()); |
455 | 156 | EXPECT_EQ("ScopeA", return_list[0].id); | 160 | EXPECT_EQ("ScopeA", return_list[0].id); |
456 | 157 | EXPECT_TRUE(return_list[0].enabled); | 161 | EXPECT_TRUE(return_list[0].enabled); |
457 | 158 | EXPECT_EQ("ScopeB", return_list[1].id); | 162 | EXPECT_EQ("ScopeB", return_list[1].id); |
458 | @@ -168,7 +172,7 @@ | |||
459 | 168 | 172 | ||
460 | 169 | // 2nd TestScope::find_child_scopes() returns: "D,A,B,C,E" | 173 | // 2nd TestScope::find_child_scopes() returns: "D,A,B,C,E" |
461 | 170 | return_list = test_scope->child_scopes(); | 174 | return_list = test_scope->child_scopes(); |
463 | 171 | ASSERT_EQ(5, return_list.size()); | 175 | ASSERT_EQ(5u, return_list.size()); |
464 | 172 | EXPECT_EQ("ScopeD", return_list[0].id); | 176 | EXPECT_EQ("ScopeD", return_list[0].id); |
465 | 173 | EXPECT_FALSE(return_list[0].enabled); | 177 | EXPECT_FALSE(return_list[0].enabled); |
466 | 174 | EXPECT_EQ("ScopeA", return_list[1].id); | 178 | EXPECT_EQ("ScopeA", return_list[1].id); |
467 | @@ -182,7 +186,7 @@ | |||
468 | 182 | 186 | ||
469 | 183 | // 3rd+ TestScope::find_child_scopes() returns: "D,A,B" | 187 | // 3rd+ TestScope::find_child_scopes() returns: "D,A,B" |
470 | 184 | return_list = test_scope->child_scopes(); | 188 | return_list = test_scope->child_scopes(); |
472 | 185 | ASSERT_EQ(3, return_list.size()); | 189 | ASSERT_EQ(3u, return_list.size()); |
473 | 186 | EXPECT_EQ("ScopeD", return_list[0].id); | 190 | EXPECT_EQ("ScopeD", return_list[0].id); |
474 | 187 | EXPECT_FALSE(return_list[0].enabled); | 191 | EXPECT_FALSE(return_list[0].enabled); |
475 | 188 | EXPECT_EQ("ScopeA", return_list[1].id); | 192 | EXPECT_EQ("ScopeA", return_list[1].id); |
476 | @@ -199,7 +203,7 @@ | |||
477 | 199 | 203 | ||
478 | 200 | // 3rd+ TestScope::find_child_scopes() returns: "D,A,B" | 204 | // 3rd+ TestScope::find_child_scopes() returns: "D,A,B" |
479 | 201 | return_list = test_scope->child_scopes(); | 205 | return_list = test_scope->child_scopes(); |
481 | 202 | ASSERT_EQ(3, return_list.size()); | 206 | ASSERT_EQ(3u, return_list.size()); |
482 | 203 | EXPECT_EQ("ScopeD", return_list[0].id); | 207 | EXPECT_EQ("ScopeD", return_list[0].id); |
483 | 204 | EXPECT_TRUE(return_list[0].enabled); | 208 | EXPECT_TRUE(return_list[0].enabled); |
484 | 205 | EXPECT_EQ("ScopeA", return_list[1].id); | 209 | EXPECT_EQ("ScopeA", return_list[1].id); |
485 | @@ -216,7 +220,7 @@ | |||
486 | 216 | 220 | ||
487 | 217 | // 1st TestScope::find_child_scopes() returns: "A,B,C" | 221 | // 1st TestScope::find_child_scopes() returns: "A,B,C" |
488 | 218 | ChildScopeList return_list = test_scope->child_scopes(); | 222 | ChildScopeList return_list = test_scope->child_scopes(); |
490 | 219 | ASSERT_EQ(3, return_list.size()); | 223 | ASSERT_EQ(3u, return_list.size()); |
491 | 220 | EXPECT_EQ("ScopeA", return_list[0].id); | 224 | EXPECT_EQ("ScopeA", return_list[0].id); |
492 | 221 | EXPECT_FALSE(return_list[0].enabled); | 225 | EXPECT_FALSE(return_list[0].enabled); |
493 | 222 | EXPECT_EQ("ScopeB", return_list[1].id); | 226 | EXPECT_EQ("ScopeB", return_list[1].id); |
494 | @@ -242,7 +246,7 @@ | |||
495 | 242 | 246 | ||
496 | 243 | // 1st TestScope::find_child_scopes() returns: "A,B,C" | 247 | // 1st TestScope::find_child_scopes() returns: "A,B,C" |
497 | 244 | ChildScopeList return_list = test_scope->child_scopes(); | 248 | ChildScopeList return_list = test_scope->child_scopes(); |
499 | 245 | ASSERT_EQ(3, return_list.size()); | 249 | ASSERT_EQ(3u, return_list.size()); |
500 | 246 | EXPECT_EQ("ScopeA", return_list[0].id); | 250 | EXPECT_EQ("ScopeA", return_list[0].id); |
501 | 247 | EXPECT_TRUE(return_list[0].enabled); | 251 | EXPECT_TRUE(return_list[0].enabled); |
502 | 248 | EXPECT_EQ("ScopeB", return_list[1].id); | 252 | EXPECT_EQ("ScopeB", return_list[1].id); |
503 | @@ -263,7 +267,7 @@ | |||
504 | 263 | 267 | ||
505 | 264 | // 1st TestScope::find_child_scopes() returns: "A,B,C" | 268 | // 1st TestScope::find_child_scopes() returns: "A,B,C" |
506 | 265 | ChildScopeList return_list = test_scope->child_scopes(); | 269 | ChildScopeList return_list = test_scope->child_scopes(); |
508 | 266 | ASSERT_EQ(3, return_list.size()); | 270 | ASSERT_EQ(3u, return_list.size()); |
509 | 267 | EXPECT_EQ("ScopeA", return_list[0].id); | 271 | EXPECT_EQ("ScopeA", return_list[0].id); |
510 | 268 | EXPECT_TRUE(return_list[0].enabled); | 272 | EXPECT_TRUE(return_list[0].enabled); |
511 | 269 | EXPECT_EQ("ScopeB", return_list[1].id); | 273 | EXPECT_EQ("ScopeB", return_list[1].id); |
512 | @@ -278,7 +282,7 @@ | |||
513 | 278 | 282 | ||
514 | 279 | // Check that nothing crashes and we simply get the list from the scope as is | 283 | // Check that nothing crashes and we simply get the list from the scope as is |
515 | 280 | return_list = test_scope->child_scopes(); | 284 | return_list = test_scope->child_scopes(); |
517 | 281 | ASSERT_EQ(3, return_list.size()); | 285 | ASSERT_EQ(3u, return_list.size()); |
518 | 282 | EXPECT_EQ("ScopeA", return_list[0].id); | 286 | EXPECT_EQ("ScopeA", return_list[0].id); |
519 | 283 | EXPECT_TRUE(return_list[0].enabled); | 287 | EXPECT_TRUE(return_list[0].enabled); |
520 | 284 | EXPECT_EQ("ScopeB", return_list[1].id); | 288 | EXPECT_EQ("ScopeB", return_list[1].id); |
521 | @@ -293,7 +297,7 @@ | |||
522 | 293 | 297 | ||
523 | 294 | // Check that nothing crashes and we simply get the list from the scope as is | 298 | // Check that nothing crashes and we simply get the list from the scope as is |
524 | 295 | return_list = test_scope->child_scopes(); | 299 | return_list = test_scope->child_scopes(); |
526 | 296 | ASSERT_EQ(3, return_list.size()); | 300 | ASSERT_EQ(3u, return_list.size()); |
527 | 297 | EXPECT_EQ("ScopeA", return_list[0].id); | 301 | EXPECT_EQ("ScopeA", return_list[0].id); |
528 | 298 | EXPECT_TRUE(return_list[0].enabled); | 302 | EXPECT_TRUE(return_list[0].enabled); |
529 | 299 | EXPECT_EQ("ScopeB", return_list[1].id); | 303 | EXPECT_EQ("ScopeB", return_list[1].id); |
530 | 300 | 304 | ||
531 | === modified file 'test/gtest/scopes/Aggregation/Keywords_test.cpp' | |||
532 | --- test/gtest/scopes/Aggregation/Keywords_test.cpp 2015-12-18 09:21:53 +0000 | |||
533 | +++ test/gtest/scopes/Aggregation/Keywords_test.cpp 2017-01-16 06:43:13 +0000 | |||
534 | @@ -21,7 +21,11 @@ | |||
535 | 21 | #include <unity/scopes/testing/ScopeMetadataBuilder.h> | 21 | #include <unity/scopes/testing/ScopeMetadataBuilder.h> |
536 | 22 | 22 | ||
537 | 23 | #include <boost/filesystem/operations.hpp> | 23 | #include <boost/filesystem/operations.hpp> |
538 | 24 | |||
539 | 25 | #pragma GCC diagnostic push | ||
540 | 26 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
541 | 24 | #include <gtest/gtest.h> | 27 | #include <gtest/gtest.h> |
542 | 28 | #pragma GCC diagnostic pop | ||
543 | 25 | 29 | ||
544 | 26 | #include "AggTestScope.h" | 30 | #include "AggTestScope.h" |
545 | 27 | 31 | ||
546 | @@ -157,7 +161,7 @@ | |||
547 | 157 | 161 | ||
548 | 158 | // Should see all scopes' results here as all children are enabled by default | 162 | // Should see all scopes' results here as all children are enabled by default |
549 | 159 | auto r = receiver->results(); | 163 | auto r = receiver->results(); |
551 | 160 | EXPECT_EQ(4, r.size()); | 164 | EXPECT_EQ(4u, r.size()); |
552 | 161 | EXPECT_TRUE(r.find("A") != r.end()); | 165 | EXPECT_TRUE(r.find("A") != r.end()); |
553 | 162 | EXPECT_TRUE(r.find("B") != r.end()); | 166 | EXPECT_TRUE(r.find("B") != r.end()); |
554 | 163 | EXPECT_TRUE(r.find("C") != r.end()); | 167 | EXPECT_TRUE(r.find("C") != r.end()); |
555 | @@ -178,7 +182,7 @@ | |||
556 | 178 | 182 | ||
557 | 179 | // Should not see scope C's results here as it has been disabled | 183 | // Should not see scope C's results here as it has been disabled |
558 | 180 | r = receiver->results(); | 184 | r = receiver->results(); |
560 | 181 | EXPECT_EQ(3, r.size()); | 185 | EXPECT_EQ(3u, r.size()); |
561 | 182 | EXPECT_TRUE(r.find("A") != r.end()); | 186 | EXPECT_TRUE(r.find("A") != r.end()); |
562 | 183 | EXPECT_TRUE(r.find("B") != r.end()); | 187 | EXPECT_TRUE(r.find("B") != r.end()); |
563 | 184 | EXPECT_TRUE(r.find("D") != r.end()); | 188 | EXPECT_TRUE(r.find("D") != r.end()); |
564 | @@ -198,7 +202,7 @@ | |||
565 | 198 | 202 | ||
566 | 199 | // Should not see scope C and D's results here as they are disabled | 203 | // Should not see scope C and D's results here as they are disabled |
567 | 200 | r = receiver->results(); | 204 | r = receiver->results(); |
569 | 201 | EXPECT_EQ(2, r.size()); | 205 | EXPECT_EQ(2u, r.size()); |
570 | 202 | EXPECT_TRUE(r.find("A") != r.end()); | 206 | EXPECT_TRUE(r.find("A") != r.end()); |
571 | 203 | EXPECT_TRUE(r.find("B") != r.end()); | 207 | EXPECT_TRUE(r.find("B") != r.end()); |
572 | 204 | 208 | ||
573 | @@ -217,7 +221,7 @@ | |||
574 | 217 | 221 | ||
575 | 218 | // Should not see scope D's results here as it is still disabled | 222 | // Should not see scope D's results here as it is still disabled |
576 | 219 | r = receiver->results(); | 223 | r = receiver->results(); |
578 | 220 | EXPECT_EQ(3, r.size()); | 224 | EXPECT_EQ(3u, r.size()); |
579 | 221 | EXPECT_TRUE(r.find("A") != r.end()); | 225 | EXPECT_TRUE(r.find("A") != r.end()); |
580 | 222 | EXPECT_TRUE(r.find("B") != r.end()); | 226 | EXPECT_TRUE(r.find("B") != r.end()); |
581 | 223 | EXPECT_TRUE(r.find("C") != r.end()); | 227 | EXPECT_TRUE(r.find("C") != r.end()); |
582 | @@ -237,7 +241,7 @@ | |||
583 | 237 | 241 | ||
584 | 238 | // Should see all scopes' results here as all children are enabled again | 242 | // Should see all scopes' results here as all children are enabled again |
585 | 239 | r = receiver->results(); | 243 | r = receiver->results(); |
587 | 240 | EXPECT_EQ(4, r.size()); | 244 | EXPECT_EQ(4u, r.size()); |
588 | 241 | EXPECT_TRUE(r.find("A") != r.end()); | 245 | EXPECT_TRUE(r.find("A") != r.end()); |
589 | 242 | EXPECT_TRUE(r.find("B") != r.end()); | 246 | EXPECT_TRUE(r.find("B") != r.end()); |
590 | 243 | EXPECT_TRUE(r.find("C") != r.end()); | 247 | EXPECT_TRUE(r.find("C") != r.end()); |
591 | @@ -267,7 +271,7 @@ | |||
592 | 267 | 271 | ||
593 | 268 | // Should see all scopes' results here as all children are enabled by default | 272 | // Should see all scopes' results here as all children are enabled by default |
594 | 269 | auto r = receiver->results(); | 273 | auto r = receiver->results(); |
596 | 270 | EXPECT_EQ(4, r.size()); | 274 | EXPECT_EQ(4u, r.size()); |
597 | 271 | EXPECT_TRUE(r.find("A") != r.end()); | 275 | EXPECT_TRUE(r.find("A") != r.end()); |
598 | 272 | EXPECT_TRUE(r.find("B") != r.end()); | 276 | EXPECT_TRUE(r.find("B") != r.end()); |
599 | 273 | EXPECT_TRUE(r.find("C") != r.end()); | 277 | EXPECT_TRUE(r.find("C") != r.end()); |
600 | 274 | 278 | ||
601 | === modified file 'test/gtest/scopes/Aggregation/LoopDetection_test.cpp' | |||
602 | --- test/gtest/scopes/Aggregation/LoopDetection_test.cpp 2015-11-23 10:09:11 +0000 | |||
603 | +++ test/gtest/scopes/Aggregation/LoopDetection_test.cpp 2017-01-16 06:43:13 +0000 | |||
604 | @@ -20,7 +20,10 @@ | |||
605 | 20 | #include <unity/scopes/internal/RuntimeImpl.h> | 20 | #include <unity/scopes/internal/RuntimeImpl.h> |
606 | 21 | #include <unity/scopes/SearchMetadata.h> | 21 | #include <unity/scopes/SearchMetadata.h> |
607 | 22 | 22 | ||
608 | 23 | #pragma GCC diagnostic push | ||
609 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
610 | 23 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
611 | 26 | #pragma GCC diagnostic pop | ||
612 | 24 | 27 | ||
613 | 25 | #include "AggTestScope.h" | 28 | #include "AggTestScope.h" |
614 | 26 | 29 | ||
615 | @@ -124,7 +127,7 @@ | |||
616 | 124 | receiver->wait_until_finished(); | 127 | receiver->wait_until_finished(); |
617 | 125 | 128 | ||
618 | 126 | auto r = receiver->results(); | 129 | auto r = receiver->results(); |
620 | 127 | EXPECT_EQ(3, r.size()); | 130 | EXPECT_EQ(3u, r.size()); |
621 | 128 | EXPECT_TRUE(r.find("A") != r.end()); | 131 | EXPECT_TRUE(r.find("A") != r.end()); |
622 | 129 | EXPECT_TRUE(r.find("B") != r.end()); | 132 | EXPECT_TRUE(r.find("B") != r.end()); |
623 | 130 | EXPECT_TRUE(r.find("C") != r.end()); | 133 | EXPECT_TRUE(r.find("C") != r.end()); |
624 | @@ -141,12 +144,12 @@ | |||
625 | 141 | receiver->wait_until_finished(); | 144 | receiver->wait_until_finished(); |
626 | 142 | 145 | ||
627 | 143 | auto r = receiver->results(); | 146 | auto r = receiver->results(); |
629 | 144 | EXPECT_EQ(4, r.size()); | 147 | EXPECT_EQ(4u, r.size()); |
630 | 145 | EXPECT_TRUE(r.find("A") != r.end()); | 148 | EXPECT_TRUE(r.find("A") != r.end()); |
631 | 146 | EXPECT_TRUE(r.find("B") != r.end()); | 149 | EXPECT_TRUE(r.find("B") != r.end()); |
632 | 147 | EXPECT_TRUE(r.find("C") != r.end()); | 150 | EXPECT_TRUE(r.find("C") != r.end()); |
633 | 148 | EXPECT_TRUE(r.find("D") != r.end()); | 151 | EXPECT_TRUE(r.find("D") != r.end()); |
635 | 149 | EXPECT_EQ(2, r.find("D")->second.size()); // B, and C each forwarded to D, so there must be 2 results. | 152 | EXPECT_EQ(2u, r.find("D")->second.size()); // B, and C each forwarded to D, so there must be 2 results. |
636 | 150 | } | 153 | } |
637 | 151 | 154 | ||
638 | 152 | TEST_F(LoopDetectionTest, immediate_loop) | 155 | TEST_F(LoopDetectionTest, immediate_loop) |
639 | @@ -157,8 +160,8 @@ | |||
640 | 157 | receiver->wait_until_finished(); | 160 | receiver->wait_until_finished(); |
641 | 158 | 161 | ||
642 | 159 | auto r = receiver->results(); | 162 | auto r = receiver->results(); |
645 | 160 | EXPECT_EQ(1, r.size()); | 163 | EXPECT_EQ(1u, r.size()); |
646 | 161 | EXPECT_EQ(3, r.find("A")->second.size()); // "A" has sent the query twice to itself, second attempt stops loop | 164 | EXPECT_EQ(3u, r.find("A")->second.size()); // "A" has sent the query twice to itself, second attempt stops loop |
647 | 162 | } | 165 | } |
648 | 163 | 166 | ||
649 | 164 | TEST_F(LoopDetectionTest, intermediate_loop) | 167 | TEST_F(LoopDetectionTest, intermediate_loop) |
650 | @@ -171,10 +174,10 @@ | |||
651 | 171 | receiver->wait_until_finished(); | 174 | receiver->wait_until_finished(); |
652 | 172 | 175 | ||
653 | 173 | auto r = receiver->results(); | 176 | auto r = receiver->results(); |
658 | 174 | EXPECT_EQ(3, r.size()); | 177 | EXPECT_EQ(3u, r.size()); |
659 | 175 | EXPECT_EQ(2, r.find("A")->second.size()); // "A" got results from B and C | 178 | EXPECT_EQ(2u, r.find("A")->second.size()); // "A" got results from B and C |
660 | 176 | EXPECT_EQ(2, r.find("B")->second.size()); // "B" got results from C and A | 179 | EXPECT_EQ(2u, r.find("B")->second.size()); // "B" got results from C and A |
661 | 177 | EXPECT_EQ(1, r.find("C")->second.size()); // "C" got result from A | 180 | EXPECT_EQ(1u, r.find("C")->second.size()); // "C" got result from A |
662 | 178 | } | 181 | } |
663 | 179 | 182 | ||
664 | 180 | TEST_F(LoopDetectionTest, repeated_search_on_leaf) | 183 | TEST_F(LoopDetectionTest, repeated_search_on_leaf) |
665 | @@ -188,11 +191,11 @@ | |||
666 | 188 | receiver->wait_until_finished(); | 191 | receiver->wait_until_finished(); |
667 | 189 | 192 | ||
668 | 190 | auto r = receiver->results(); | 193 | auto r = receiver->results(); |
674 | 191 | EXPECT_EQ(4, r.size()); | 194 | EXPECT_EQ(4u, r.size()); |
675 | 192 | EXPECT_EQ(1, r.find("A")->second.size()); | 195 | EXPECT_EQ(1u, r.find("A")->second.size()); |
676 | 193 | EXPECT_EQ(1, r.find("B")->second.size()); | 196 | EXPECT_EQ(1u, r.find("B")->second.size()); |
677 | 194 | EXPECT_EQ(1, r.find("C")->second.size()); | 197 | EXPECT_EQ(1u, r.find("C")->second.size()); |
678 | 195 | EXPECT_EQ(3, r.find("D")->second.size()); | 198 | EXPECT_EQ(3u, r.find("D")->second.size()); |
679 | 196 | } | 199 | } |
680 | 197 | 200 | ||
681 | 198 | TEST_F(LoopDetectionTest, repeated_search_on_aggregator) | 201 | TEST_F(LoopDetectionTest, repeated_search_on_aggregator) |
682 | @@ -206,10 +209,10 @@ | |||
683 | 206 | receiver->wait_until_finished(); | 209 | receiver->wait_until_finished(); |
684 | 207 | 210 | ||
685 | 208 | auto r = receiver->results(); | 211 | auto r = receiver->results(); |
690 | 209 | EXPECT_EQ(3, r.size()); | 212 | EXPECT_EQ(3u, r.size()); |
691 | 210 | EXPECT_EQ(1, r.find("A")->second.size()); | 213 | EXPECT_EQ(1u, r.find("A")->second.size()); |
692 | 211 | EXPECT_EQ(1, r.find("B")->second.size()); | 214 | EXPECT_EQ(1u, r.find("B")->second.size()); |
693 | 212 | EXPECT_EQ(1, r.find("C")->second.size()); | 215 | EXPECT_EQ(1u, r.find("C")->second.size()); |
694 | 213 | } | 216 | } |
695 | 214 | 217 | ||
696 | 215 | #pragma GCC diagnostic pop | 218 | #pragma GCC diagnostic pop |
697 | 216 | 219 | ||
698 | === modified file 'test/gtest/scopes/Annotation/Annotation_test.cpp' | |||
699 | --- test/gtest/scopes/Annotation/Annotation_test.cpp 2014-11-18 07:04:04 +0000 | |||
700 | +++ test/gtest/scopes/Annotation/Annotation_test.cpp 2017-01-16 06:43:13 +0000 | |||
701 | @@ -16,7 +16,11 @@ | |||
702 | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> |
703 | 17 | */ | 17 | */ |
704 | 18 | 18 | ||
705 | 19 | #pragma GCC diagnostic push | ||
706 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
707 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
708 | 22 | #pragma GCC diagnostic pop | ||
709 | 23 | |||
710 | 20 | #include <unity/scopes/Annotation.h> | 24 | #include <unity/scopes/Annotation.h> |
711 | 21 | #include <unity/scopes/CannedQuery.h> | 25 | #include <unity/scopes/CannedQuery.h> |
712 | 22 | #include <unity/scopes/internal/CannedQueryImpl.h> | 26 | #include <unity/scopes/internal/CannedQueryImpl.h> |
713 | 23 | 27 | ||
714 | === modified file 'test/gtest/scopes/CannedQuery/CannedQuery_test.cpp' | |||
715 | --- test/gtest/scopes/CannedQuery/CannedQuery_test.cpp 2015-02-27 09:43:40 +0000 | |||
716 | +++ test/gtest/scopes/CannedQuery/CannedQuery_test.cpp 2017-01-16 06:43:13 +0000 | |||
717 | @@ -16,7 +16,11 @@ | |||
718 | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> |
719 | 17 | */ | 17 | */ |
720 | 18 | 18 | ||
721 | 19 | #pragma GCC diagnostic push | ||
722 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
723 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
724 | 22 | #pragma GCC diagnostic pop | ||
725 | 23 | |||
726 | 20 | #include <unity/scopes/CannedQuery.h> | 24 | #include <unity/scopes/CannedQuery.h> |
727 | 21 | #include <unity/scopes/internal/CannedQueryImpl.h> | 25 | #include <unity/scopes/internal/CannedQueryImpl.h> |
728 | 22 | #include <unity/scopes/OptionSelectorFilter.h> | 26 | #include <unity/scopes/OptionSelectorFilter.h> |
729 | @@ -278,7 +282,7 @@ | |||
730 | 278 | filter->add_option("o1", "Option 1"); | 282 | filter->add_option("o1", "Option 1"); |
731 | 279 | filter->add_option("o2", "Option 2"); | 283 | filter->add_option("o2", "Option 2"); |
732 | 280 | auto actopts = filter->active_options(fstate); | 284 | auto actopts = filter->active_options(fstate); |
734 | 281 | EXPECT_EQ(1, actopts.size()); | 285 | EXPECT_EQ(1u, actopts.size()); |
735 | 282 | EXPECT_EQ("o1", (*(actopts.begin()))->id()); | 286 | EXPECT_EQ("o1", (*(actopts.begin()))->id()); |
736 | 283 | } | 287 | } |
737 | 284 | { | 288 | { |
738 | 285 | 289 | ||
739 | === modified file 'test/gtest/scopes/CategorisedResult/CategorisedResult_test.cpp' | |||
740 | --- test/gtest/scopes/CategorisedResult/CategorisedResult_test.cpp 2015-07-15 15:49:05 +0000 | |||
741 | +++ test/gtest/scopes/CategorisedResult/CategorisedResult_test.cpp 2017-01-16 06:43:13 +0000 | |||
742 | @@ -23,7 +23,11 @@ | |||
743 | 23 | #include <unity/scopes/internal/ReplyObject.h> | 23 | #include <unity/scopes/internal/ReplyObject.h> |
744 | 24 | #include <unity/scopes/internal/CategorisedResultImpl.h> | 24 | #include <unity/scopes/internal/CategorisedResultImpl.h> |
745 | 25 | #include <unity/UnityExceptions.h> | 25 | #include <unity/UnityExceptions.h> |
746 | 26 | |||
747 | 27 | #pragma GCC diagnostic push | ||
748 | 28 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
749 | 26 | #include <gtest/gtest.h> | 29 | #include <gtest/gtest.h> |
750 | 30 | #pragma GCC diagnostic pop | ||
751 | 27 | 31 | ||
752 | 28 | using namespace unity::scopes; | 32 | using namespace unity::scopes; |
753 | 29 | using namespace unity::scopes::internal; | 33 | using namespace unity::scopes::internal; |
754 | 30 | 34 | ||
755 | === modified file 'test/gtest/scopes/Category/Category_test.cpp' | |||
756 | --- test/gtest/scopes/Category/Category_test.cpp 2014-07-02 09:36:34 +0000 | |||
757 | +++ test/gtest/scopes/Category/Category_test.cpp 2017-01-16 06:43:13 +0000 | |||
758 | @@ -21,7 +21,10 @@ | |||
759 | 21 | #include <unity/UnityExceptions.h> | 21 | #include <unity/UnityExceptions.h> |
760 | 22 | #include <unity/scopes/Variant.h> | 22 | #include <unity/scopes/Variant.h> |
761 | 23 | 23 | ||
762 | 24 | #pragma GCC diagnostic push | ||
763 | 25 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
764 | 24 | #include <gtest/gtest.h> | 26 | #include <gtest/gtest.h> |
765 | 27 | #pragma GCC diagnostic pop | ||
766 | 25 | 28 | ||
767 | 26 | using namespace std; | 29 | using namespace std; |
768 | 27 | using namespace unity; | 30 | using namespace unity; |
769 | 28 | 31 | ||
770 | === modified file 'test/gtest/scopes/CategoryRenderer/CategoryRenderer_test.cpp' | |||
771 | --- test/gtest/scopes/CategoryRenderer/CategoryRenderer_test.cpp 2014-07-07 23:53:36 +0000 | |||
772 | +++ test/gtest/scopes/CategoryRenderer/CategoryRenderer_test.cpp 2017-01-16 06:43:13 +0000 | |||
773 | @@ -19,7 +19,11 @@ | |||
774 | 19 | #include <unity/scopes/CategoryRenderer.h> | 19 | #include <unity/scopes/CategoryRenderer.h> |
775 | 20 | #include <unity/UnityExceptions.h> | 20 | #include <unity/UnityExceptions.h> |
776 | 21 | #include <fstream> | 21 | #include <fstream> |
777 | 22 | |||
778 | 23 | #pragma GCC diagnostic push | ||
779 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
780 | 22 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
781 | 26 | #pragma GCC diagnostic pop | ||
782 | 23 | 27 | ||
783 | 24 | using namespace unity::scopes; | 28 | using namespace unity::scopes; |
784 | 25 | using namespace unity::scopes::internal; | 29 | using namespace unity::scopes::internal; |
785 | 26 | 30 | ||
786 | === modified file 'test/gtest/scopes/ColumnLayout/ColumnLayout_test.cpp' | |||
787 | --- test/gtest/scopes/ColumnLayout/ColumnLayout_test.cpp 2014-02-25 12:08:41 +0000 | |||
788 | +++ test/gtest/scopes/ColumnLayout/ColumnLayout_test.cpp 2017-01-16 06:43:13 +0000 | |||
789 | @@ -19,7 +19,11 @@ | |||
790 | 19 | #include <unity/scopes/ColumnLayout.h> | 19 | #include <unity/scopes/ColumnLayout.h> |
791 | 20 | #include <unity/scopes/internal/ColumnLayoutImpl.h> | 20 | #include <unity/scopes/internal/ColumnLayoutImpl.h> |
792 | 21 | #include <unity/UnityExceptions.h> | 21 | #include <unity/UnityExceptions.h> |
793 | 22 | |||
794 | 23 | #pragma GCC diagnostic push | ||
795 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
796 | 22 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
797 | 26 | #pragma GCC diagnostic pop | ||
798 | 23 | 27 | ||
799 | 24 | using namespace unity::scopes; | 28 | using namespace unity::scopes; |
800 | 25 | using namespace unity::scopes::internal; | 29 | using namespace unity::scopes::internal; |
801 | 26 | 30 | ||
802 | === modified file 'test/gtest/scopes/DateTimePickerFilter/DateTimePickerFilter_test.cpp' | |||
803 | --- test/gtest/scopes/DateTimePickerFilter/DateTimePickerFilter_test.cpp 2015-11-12 12:45:41 +0000 | |||
804 | +++ test/gtest/scopes/DateTimePickerFilter/DateTimePickerFilter_test.cpp 2017-01-16 06:43:13 +0000 | |||
805 | @@ -16,7 +16,11 @@ | |||
806 | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> |
807 | 17 | */ | 17 | */ |
808 | 18 | 18 | ||
809 | 19 | #pragma GCC diagnostic push | ||
810 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
811 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
812 | 22 | #pragma GCC diagnostic pop | ||
813 | 23 | |||
814 | 20 | #include <unity/scopes/FilterState.h> | 24 | #include <unity/scopes/FilterState.h> |
815 | 21 | #include <unity/scopes/DateTimePickerFilter.h> | 25 | #include <unity/scopes/DateTimePickerFilter.h> |
816 | 22 | #include <unity/scopes/internal/DateTimePickerFilterImpl.h> | 26 | #include <unity/scopes/internal/DateTimePickerFilterImpl.h> |
817 | 23 | 27 | ||
818 | === modified file 'test/gtest/scopes/Department/Department_test.cpp' | |||
819 | --- test/gtest/scopes/Department/Department_test.cpp 2014-05-28 13:52:22 +0000 | |||
820 | +++ test/gtest/scopes/Department/Department_test.cpp 2017-01-16 06:43:13 +0000 | |||
821 | @@ -20,7 +20,11 @@ | |||
822 | 20 | #include <unity/scopes/internal/DepartmentImpl.h> | 20 | #include <unity/scopes/internal/DepartmentImpl.h> |
823 | 21 | #include <unity/scopes/CannedQuery.h> | 21 | #include <unity/scopes/CannedQuery.h> |
824 | 22 | #include <unity/UnityExceptions.h> | 22 | #include <unity/UnityExceptions.h> |
825 | 23 | |||
826 | 24 | #pragma GCC diagnostic push | ||
827 | 25 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
828 | 23 | #include <gtest/gtest.h> | 26 | #include <gtest/gtest.h> |
829 | 27 | #pragma GCC diagnostic pop | ||
830 | 24 | 28 | ||
831 | 25 | using namespace unity::scopes; | 29 | using namespace unity::scopes; |
832 | 26 | using namespace unity::scopes::internal; | 30 | using namespace unity::scopes::internal; |
833 | 27 | 31 | ||
834 | === modified file 'test/gtest/scopes/Filters/Filters_test.cpp' | |||
835 | --- test/gtest/scopes/Filters/Filters_test.cpp 2016-06-14 14:54:15 +0000 | |||
836 | +++ test/gtest/scopes/Filters/Filters_test.cpp 2017-01-16 06:43:13 +0000 | |||
837 | @@ -31,8 +31,12 @@ | |||
838 | 31 | #include <unity/scopes/ValueSliderLabels.h> | 31 | #include <unity/scopes/ValueSliderLabels.h> |
839 | 32 | #include <unity/scopes/SearchMetadata.h> | 32 | #include <unity/scopes/SearchMetadata.h> |
840 | 33 | #include <unity/UnityExceptions.h> | 33 | #include <unity/UnityExceptions.h> |
841 | 34 | #include <TestScope.h> | ||
842 | 35 | |||
843 | 36 | #pragma GCC diagnostic push | ||
844 | 37 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
845 | 34 | #include <gtest/gtest.h> | 38 | #include <gtest/gtest.h> |
847 | 35 | #include <TestScope.h> | 39 | #pragma GCC diagnostic pop |
848 | 36 | 40 | ||
849 | 37 | using namespace unity::scopes; | 41 | using namespace unity::scopes; |
850 | 38 | using namespace unity::scopes::experimental; | 42 | using namespace unity::scopes::experimental; |
851 | 39 | 43 | ||
852 | === modified file 'test/gtest/scopes/IdleShutdown/IdleShutdown_test.cpp' | |||
853 | --- test/gtest/scopes/IdleShutdown/IdleShutdown_test.cpp 2015-01-09 03:16:51 +0000 | |||
854 | +++ test/gtest/scopes/IdleShutdown/IdleShutdown_test.cpp 2017-01-16 06:43:13 +0000 | |||
855 | @@ -21,7 +21,11 @@ | |||
856 | 21 | #include <unity/scopes/internal/RuntimeImpl.h> | 21 | #include <unity/scopes/internal/RuntimeImpl.h> |
857 | 22 | #include <unity/scopes/internal/ScopeImpl.h> | 22 | #include <unity/scopes/internal/ScopeImpl.h> |
858 | 23 | 23 | ||
859 | 24 | |||
860 | 25 | #pragma GCC diagnostic push | ||
861 | 26 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
862 | 24 | #include <gtest/gtest.h> | 27 | #include <gtest/gtest.h> |
863 | 28 | #pragma GCC diagnostic pop | ||
864 | 25 | 29 | ||
865 | 26 | #include "SlowSearchScope.h" | 30 | #include "SlowSearchScope.h" |
866 | 27 | 31 | ||
867 | 28 | 32 | ||
868 | === modified file 'test/gtest/scopes/Invocation/Invocation_test.cpp' | |||
869 | --- test/gtest/scopes/Invocation/Invocation_test.cpp 2015-01-09 03:16:51 +0000 | |||
870 | +++ test/gtest/scopes/Invocation/Invocation_test.cpp 2017-01-16 06:43:13 +0000 | |||
871 | @@ -30,7 +30,10 @@ | |||
872 | 30 | 30 | ||
873 | 31 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. | 31 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. |
874 | 32 | 32 | ||
875 | 33 | #pragma GCC diagnostic push | ||
876 | 34 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
877 | 33 | #include <gtest/gtest.h> | 35 | #include <gtest/gtest.h> |
878 | 36 | #pragma GCC diagnostic pop | ||
879 | 34 | 37 | ||
880 | 35 | #include "EmptyScope.h" | 38 | #include "EmptyScope.h" |
881 | 36 | #include "TestScope.h" | 39 | #include "TestScope.h" |
882 | 37 | 40 | ||
883 | === modified file 'test/gtest/scopes/Location/Location_test.cpp' | |||
884 | --- test/gtest/scopes/Location/Location_test.cpp 2015-03-06 07:56:37 +0000 | |||
885 | +++ test/gtest/scopes/Location/Location_test.cpp 2017-01-16 06:43:13 +0000 | |||
886 | @@ -18,8 +18,12 @@ | |||
887 | 18 | 18 | ||
888 | 19 | #include <unity/scopes/ScopeExceptions.h> | 19 | #include <unity/scopes/ScopeExceptions.h> |
889 | 20 | #include <unity/scopes/Location.h> | 20 | #include <unity/scopes/Location.h> |
890 | 21 | #include <unity/UnityExceptions.h> | ||
891 | 22 | |||
892 | 23 | #pragma GCC diagnostic push | ||
893 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
894 | 21 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
896 | 22 | #include <unity/UnityExceptions.h> | 26 | #pragma GCC diagnostic pop |
897 | 23 | 27 | ||
898 | 24 | using namespace unity; | 28 | using namespace unity; |
899 | 25 | using namespace unity::scopes; | 29 | using namespace unity::scopes; |
900 | 26 | 30 | ||
901 | === modified file 'test/gtest/scopes/OnlineAccountClient/OnlineAccountClient_test.cpp' | |||
902 | --- test/gtest/scopes/OnlineAccountClient/OnlineAccountClient_test.cpp 2016-03-16 09:52:22 +0000 | |||
903 | +++ test/gtest/scopes/OnlineAccountClient/OnlineAccountClient_test.cpp 2017-01-16 06:43:13 +0000 | |||
904 | @@ -28,11 +28,15 @@ | |||
905 | 28 | #include <boost/filesystem/operations.hpp> | 28 | #include <boost/filesystem/operations.hpp> |
906 | 29 | #include <condition_variable> | 29 | #include <condition_variable> |
907 | 30 | #include <functional> | 30 | #include <functional> |
908 | 31 | #include <gtest/gtest.h> | ||
909 | 32 | #include <libaccounts-glib/accounts-glib.h> | 31 | #include <libaccounts-glib/accounts-glib.h> |
910 | 33 | #include <libdbustest/dbus-test.h> | 32 | #include <libdbustest/dbus-test.h> |
911 | 34 | #include <thread> | 33 | #include <thread> |
912 | 35 | 34 | ||
913 | 35 | #pragma GCC diagnostic push | ||
914 | 36 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
915 | 37 | #include <gtest/gtest.h> | ||
916 | 38 | #pragma GCC diagnostic pop | ||
917 | 39 | |||
918 | 36 | using namespace unity; | 40 | using namespace unity; |
919 | 37 | using namespace unity::scopes; | 41 | using namespace unity::scopes; |
920 | 38 | using namespace unity::scopes::testing; | 42 | using namespace unity::scopes::testing; |
921 | @@ -421,13 +425,13 @@ | |||
922 | 421 | TEST_F(OnlineAccountClientTest, refresh_services_main_loop) | 425 | TEST_F(OnlineAccountClientTest, refresh_services_main_loop) |
923 | 422 | { | 426 | { |
924 | 423 | auto statuses = oa_client()->get_service_statuses(); | 427 | auto statuses = oa_client()->get_service_statuses(); |
926 | 424 | EXPECT_EQ(0, statuses.size()); | 428 | EXPECT_EQ(0u, statuses.size()); |
927 | 425 | 429 | ||
928 | 426 | create_account(); | 430 | create_account(); |
929 | 427 | oa_client()->refresh_service_statuses(); | 431 | oa_client()->refresh_service_statuses(); |
930 | 428 | 432 | ||
931 | 429 | statuses = oa_client()->get_service_statuses(); | 433 | statuses = oa_client()->get_service_statuses(); |
933 | 430 | EXPECT_EQ(1, statuses.size()); | 434 | EXPECT_EQ(1u, statuses.size()); |
934 | 431 | EXPECT_FALSE(statuses[0].service_enabled); | 435 | EXPECT_FALSE(statuses[0].service_enabled); |
935 | 432 | 436 | ||
936 | 433 | enable_service(); | 437 | enable_service(); |
937 | @@ -464,7 +468,7 @@ | |||
938 | 464 | oa_client()->refresh_service_statuses(); | 468 | oa_client()->refresh_service_statuses(); |
939 | 465 | 469 | ||
940 | 466 | statuses = oa_client()->get_service_statuses(); | 470 | statuses = oa_client()->get_service_statuses(); |
942 | 467 | EXPECT_EQ(0, statuses.size()); | 471 | EXPECT_EQ(0u, statuses.size()); |
943 | 468 | } | 472 | } |
944 | 469 | 473 | ||
945 | 470 | TEST_F(OnlineAccountClientTest, service_update_callback) | 474 | TEST_F(OnlineAccountClientTest, service_update_callback) |
946 | 471 | 475 | ||
947 | === modified file 'test/gtest/scopes/OptionSelectorFilter/OptionSelectorFilter_test.cpp' | |||
948 | --- test/gtest/scopes/OptionSelectorFilter/OptionSelectorFilter_test.cpp 2016-03-09 12:06:02 +0000 | |||
949 | +++ test/gtest/scopes/OptionSelectorFilter/OptionSelectorFilter_test.cpp 2017-01-16 06:43:13 +0000 | |||
950 | @@ -16,7 +16,12 @@ | |||
951 | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> |
952 | 17 | */ | 17 | */ |
953 | 18 | 18 | ||
954 | 19 | |||
955 | 20 | #pragma GCC diagnostic push | ||
956 | 21 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
957 | 19 | #include <gtest/gtest.h> | 22 | #include <gtest/gtest.h> |
958 | 23 | #pragma GCC diagnostic pop | ||
959 | 24 | |||
960 | 20 | #include <unity/scopes/FilterState.h> | 25 | #include <unity/scopes/FilterState.h> |
961 | 21 | #include <unity/scopes/OptionSelectorFilter.h> | 26 | #include <unity/scopes/OptionSelectorFilter.h> |
962 | 22 | #include <unity/scopes/internal/OptionSelectorFilterImpl.h> | 27 | #include <unity/scopes/internal/OptionSelectorFilterImpl.h> |
963 | 23 | 28 | ||
964 | === modified file 'test/gtest/scopes/PreviewWidget/PreviewWidget_test.cpp' | |||
965 | --- test/gtest/scopes/PreviewWidget/PreviewWidget_test.cpp 2014-08-29 14:11:24 +0000 | |||
966 | +++ test/gtest/scopes/PreviewWidget/PreviewWidget_test.cpp 2017-01-16 06:43:13 +0000 | |||
967 | @@ -21,7 +21,11 @@ | |||
968 | 21 | #include <unity/UnityExceptions.h> | 21 | #include <unity/UnityExceptions.h> |
969 | 22 | #include <unity/scopes/Variant.h> | 22 | #include <unity/scopes/Variant.h> |
970 | 23 | #include <unity/scopes/internal/JsonCppNode.h> | 23 | #include <unity/scopes/internal/JsonCppNode.h> |
971 | 24 | |||
972 | 25 | #pragma GCC diagnostic push | ||
973 | 26 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
974 | 24 | #include <gtest/gtest.h> | 27 | #include <gtest/gtest.h> |
975 | 28 | #pragma GCC diagnostic pop | ||
976 | 25 | 29 | ||
977 | 26 | using namespace unity::scopes; | 30 | using namespace unity::scopes; |
978 | 27 | using namespace unity::scopes::internal; | 31 | using namespace unity::scopes::internal; |
979 | 28 | 32 | ||
980 | === modified file 'test/gtest/scopes/QueryMetadata/QueryMetadata_test.cpp' | |||
981 | --- test/gtest/scopes/QueryMetadata/QueryMetadata_test.cpp 2015-10-29 06:24:06 +0000 | |||
982 | +++ test/gtest/scopes/QueryMetadata/QueryMetadata_test.cpp 2017-01-16 06:43:13 +0000 | |||
983 | @@ -21,8 +21,12 @@ | |||
984 | 21 | #include <unity/scopes/ActionMetadata.h> | 21 | #include <unity/scopes/ActionMetadata.h> |
985 | 22 | #include <unity/scopes/internal/ActionMetadataImpl.h> | 22 | #include <unity/scopes/internal/ActionMetadataImpl.h> |
986 | 23 | #include <unity/scopes/internal/SearchMetadataImpl.h> | 23 | #include <unity/scopes/internal/SearchMetadataImpl.h> |
987 | 24 | #include <unity/UnityExceptions.h> | ||
988 | 25 | |||
989 | 26 | #pragma GCC diagnostic push | ||
990 | 27 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
991 | 24 | #include <gtest/gtest.h> | 28 | #include <gtest/gtest.h> |
993 | 25 | #include <unity/UnityExceptions.h> | 29 | #pragma GCC diagnostic pop |
994 | 26 | 30 | ||
995 | 27 | using namespace unity; | 31 | using namespace unity; |
996 | 28 | using namespace unity::scopes; | 32 | using namespace unity::scopes; |
997 | 29 | 33 | ||
998 | === modified file 'test/gtest/scopes/RadioButtonsFilter/RadioButtonsFilter_test.cpp' | |||
999 | --- test/gtest/scopes/RadioButtonsFilter/RadioButtonsFilter_test.cpp 2015-11-12 12:45:41 +0000 | |||
1000 | +++ test/gtest/scopes/RadioButtonsFilter/RadioButtonsFilter_test.cpp 2017-01-16 06:43:13 +0000 | |||
1001 | @@ -16,7 +16,11 @@ | |||
1002 | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> |
1003 | 17 | */ | 17 | */ |
1004 | 18 | 18 | ||
1005 | 19 | #pragma GCC diagnostic push | ||
1006 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1007 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
1008 | 22 | #pragma GCC diagnostic pop | ||
1009 | 23 | |||
1010 | 20 | #include <unity/scopes/FilterState.h> | 24 | #include <unity/scopes/FilterState.h> |
1011 | 21 | #include <unity/scopes/RadioButtonsFilter.h> | 25 | #include <unity/scopes/RadioButtonsFilter.h> |
1012 | 22 | #include <unity/UnityExceptions.h> | 26 | #include <unity/UnityExceptions.h> |
1013 | 23 | 27 | ||
1014 | === modified file 'test/gtest/scopes/RangeInputFilter/RangeInputFilter_test.cpp' | |||
1015 | --- test/gtest/scopes/RangeInputFilter/RangeInputFilter_test.cpp 2016-03-09 11:33:52 +0000 | |||
1016 | +++ test/gtest/scopes/RangeInputFilter/RangeInputFilter_test.cpp 2017-01-16 06:43:13 +0000 | |||
1017 | @@ -16,7 +16,11 @@ | |||
1018 | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> |
1019 | 17 | */ | 17 | */ |
1020 | 18 | 18 | ||
1021 | 19 | #pragma GCC diagnostic push | ||
1022 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1023 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
1024 | 22 | #pragma GCC diagnostic pop | ||
1025 | 23 | |||
1026 | 20 | #include <cmath> | 24 | #include <cmath> |
1027 | 21 | #include <unity/scopes/FilterState.h> | 25 | #include <unity/scopes/FilterState.h> |
1028 | 22 | #include <unity/scopes/RangeInputFilter.h> | 26 | #include <unity/scopes/RangeInputFilter.h> |
1029 | 23 | 27 | ||
1030 | === modified file 'test/gtest/scopes/RatingFilter/RatingFilter_test.cpp' | |||
1031 | --- test/gtest/scopes/RatingFilter/RatingFilter_test.cpp 2014-06-17 10:30:03 +0000 | |||
1032 | +++ test/gtest/scopes/RatingFilter/RatingFilter_test.cpp 2017-01-16 06:43:13 +0000 | |||
1033 | @@ -16,7 +16,12 @@ | |||
1034 | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> |
1035 | 17 | */ | 17 | */ |
1036 | 18 | 18 | ||
1037 | 19 | |||
1038 | 20 | #pragma GCC diagnostic push | ||
1039 | 21 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1040 | 19 | #include <gtest/gtest.h> | 22 | #include <gtest/gtest.h> |
1041 | 23 | #pragma GCC diagnostic pop | ||
1042 | 24 | |||
1043 | 20 | #include <unity/scopes/FilterState.h> | 25 | #include <unity/scopes/FilterState.h> |
1044 | 21 | #include <unity/scopes/RatingFilter.h> | 26 | #include <unity/scopes/RatingFilter.h> |
1045 | 22 | #include <unity/UnityExceptions.h> | 27 | #include <unity/UnityExceptions.h> |
1046 | 23 | 28 | ||
1047 | === modified file 'test/gtest/scopes/Registry/Registry_test.cpp' | |||
1048 | --- test/gtest/scopes/Registry/Registry_test.cpp 2016-03-31 09:27:33 +0000 | |||
1049 | +++ test/gtest/scopes/Registry/Registry_test.cpp 2017-01-16 06:43:13 +0000 | |||
1050 | @@ -24,7 +24,11 @@ | |||
1051 | 24 | #include <unity/scopes/SearchMetadata.h> | 24 | #include <unity/scopes/SearchMetadata.h> |
1052 | 25 | 25 | ||
1053 | 26 | #include <boost/filesystem/operations.hpp> | 26 | #include <boost/filesystem/operations.hpp> |
1054 | 27 | |||
1055 | 28 | #pragma GCC diagnostic push | ||
1056 | 29 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1057 | 27 | #include <gtest/gtest.h> | 30 | #include <gtest/gtest.h> |
1058 | 31 | #pragma GCC diagnostic pop | ||
1059 | 28 | 32 | ||
1060 | 29 | #include <chrono> | 33 | #include <chrono> |
1061 | 30 | #include <condition_variable> | 34 | #include <condition_variable> |
1062 | @@ -79,6 +83,12 @@ | |||
1063 | 79 | std::condition_variable cond_; | 83 | std::condition_variable cond_; |
1064 | 80 | }; | 84 | }; |
1065 | 81 | 85 | ||
1066 | 86 | TEST(Registry, desktop_dir_does_not_exist) | ||
1067 | 87 | { | ||
1068 | 88 | // Directory does not exist to start with. | ||
1069 | 89 | EXPECT_FALSE(filesystem::is_directory(TEST_RUNTIME_PATH "/applications")); | ||
1070 | 90 | } | ||
1071 | 91 | |||
1072 | 82 | TEST(Registry, metadata) | 92 | TEST(Registry, metadata) |
1073 | 83 | { | 93 | { |
1074 | 84 | Runtime::UPtr rt = Runtime::create(TEST_RUNTIME_FILE); | 94 | Runtime::UPtr rt = Runtime::create(TEST_RUNTIME_FILE); |
1075 | @@ -96,7 +106,7 @@ | |||
1076 | 96 | EXPECT_EQ("scope-A.SearchHint", meta.search_hint()); | 106 | EXPECT_EQ("scope-A.SearchHint", meta.search_hint()); |
1077 | 97 | EXPECT_EQ(TEST_RUNTIME_PATH "/scopes/testscopeA", meta.scope_directory()); | 107 | EXPECT_EQ(TEST_RUNTIME_PATH "/scopes/testscopeA", meta.scope_directory()); |
1078 | 98 | auto defs = meta.settings_definitions(); | 108 | auto defs = meta.settings_definitions(); |
1080 | 99 | ASSERT_EQ(2, defs.size()); | 109 | ASSERT_EQ(2u, defs.size()); |
1081 | 100 | EXPECT_EQ("locationSetting", defs[0].get_dict()["id"].get_string()); | 110 | EXPECT_EQ("locationSetting", defs[0].get_dict()["id"].get_string()); |
1082 | 101 | EXPECT_EQ("Location", defs[0].get_dict()["displayName"].get_string()); | 111 | EXPECT_EQ("Location", defs[0].get_dict()["displayName"].get_string()); |
1083 | 102 | EXPECT_EQ("string", defs[0].get_dict()["type"].get_string()); | 112 | EXPECT_EQ("string", defs[0].get_dict()["type"].get_string()); |
1084 | @@ -144,14 +154,20 @@ | |||
1085 | 144 | EXPECT_EQ("scope-B.SearchHint", meta.search_hint()); | 154 | EXPECT_EQ("scope-B.SearchHint", meta.search_hint()); |
1086 | 145 | EXPECT_EQ(TEST_RUNTIME_PATH "/scopes/testscopeB", meta.scope_directory()); | 155 | EXPECT_EQ(TEST_RUNTIME_PATH "/scopes/testscopeB", meta.scope_directory()); |
1087 | 146 | defs = meta.settings_definitions(); | 156 | defs = meta.settings_definitions(); |
1089 | 147 | EXPECT_EQ(0, defs.size()); | 157 | EXPECT_EQ(0u, defs.size()); |
1090 | 148 | EXPECT_FALSE(meta.location_data_needed()); | 158 | EXPECT_FALSE(meta.location_data_needed()); |
1093 | 149 | EXPECT_EQ(0, meta.child_scope_ids().size()); | 159 | EXPECT_EQ(0u, meta.child_scope_ids().size()); |
1094 | 150 | EXPECT_EQ(0, meta.keywords().size()); | 160 | EXPECT_EQ(0u, meta.keywords().size()); |
1095 | 151 | EXPECT_EQ(0, meta.version()); | 161 | EXPECT_EQ(0, meta.version()); |
1096 | 152 | EXPECT_FALSE(meta.is_aggregator()); | 162 | EXPECT_FALSE(meta.is_aggregator()); |
1097 | 153 | } | 163 | } |
1098 | 154 | 164 | ||
1099 | 165 | TEST(Registry, desktop_dir_exists) | ||
1100 | 166 | { | ||
1101 | 167 | // Directory must have been created. | ||
1102 | 168 | EXPECT_TRUE(filesystem::is_directory(TEST_RUNTIME_PATH "/applications")); | ||
1103 | 169 | } | ||
1104 | 170 | |||
1105 | 155 | auto const wait_for_update_time = std::chrono::milliseconds(5000); | 171 | auto const wait_for_update_time = std::chrono::milliseconds(5000); |
1106 | 156 | 172 | ||
1107 | 157 | TEST(Registry, scope_state_notify) | 173 | TEST(Registry, scope_state_notify) |
1108 | @@ -211,7 +227,7 @@ | |||
1109 | 211 | 227 | ||
1110 | 212 | auto meta = r->get_metadata("testscopeA"); | 228 | auto meta = r->get_metadata("testscopeA"); |
1111 | 213 | auto defs = meta.settings_definitions(); | 229 | auto defs = meta.settings_definitions(); |
1113 | 214 | EXPECT_EQ(2, defs.size()); | 230 | EXPECT_EQ(2u, defs.size()); |
1114 | 215 | auto sp = meta.proxy(); | 231 | auto sp = meta.proxy(); |
1115 | 216 | 232 | ||
1116 | 217 | // testscopeA should not be running at this point | 233 | // testscopeA should not be running at this point |
1117 | @@ -228,7 +244,7 @@ | |||
1118 | 228 | 244 | ||
1119 | 229 | meta = r->get_metadata("testscopeB"); | 245 | meta = r->get_metadata("testscopeB"); |
1120 | 230 | defs = meta.settings_definitions(); | 246 | defs = meta.settings_definitions(); |
1122 | 231 | EXPECT_EQ(0, defs.size()); | 247 | EXPECT_EQ(0u, defs.size()); |
1123 | 232 | sp = meta.proxy(); | 248 | sp = meta.proxy(); |
1124 | 233 | 249 | ||
1125 | 234 | // testscopeB should not be running at this point | 250 | // testscopeB should not be running at this point |
1126 | @@ -478,7 +494,7 @@ | |||
1127 | 478 | 494 | ||
1128 | 479 | // First check that we have 2 scopes registered | 495 | // First check that we have 2 scopes registered |
1129 | 480 | MetadataMap list = r->list(); | 496 | MetadataMap list = r->list(); |
1131 | 481 | EXPECT_EQ(2, list.size()); | 497 | EXPECT_EQ(2u, list.size()); |
1132 | 482 | EXPECT_NE(list.end(), list.find("testscopeA")); | 498 | EXPECT_NE(list.end(), list.find("testscopeA")); |
1133 | 483 | EXPECT_NE(list.end(), list.find("testscopeB")); | 499 | EXPECT_NE(list.end(), list.find("testscopeB")); |
1134 | 484 | EXPECT_EQ(list.end(), list.find("testscopeC")); | 500 | EXPECT_EQ(list.end(), list.find("testscopeC")); |
1135 | @@ -496,7 +512,7 @@ | |||
1136 | 496 | 512 | ||
1137 | 497 | // Now check that we have 3 scopes registered | 513 | // Now check that we have 3 scopes registered |
1138 | 498 | list = r->list(); | 514 | list = r->list(); |
1140 | 499 | EXPECT_EQ(3, list.size()); | 515 | EXPECT_EQ(3u, list.size()); |
1141 | 500 | EXPECT_NE(list.end(), list.find("testscopeA")); | 516 | EXPECT_NE(list.end(), list.find("testscopeA")); |
1142 | 501 | EXPECT_NE(list.end(), list.find("testscopeB")); | 517 | EXPECT_NE(list.end(), list.find("testscopeB")); |
1143 | 502 | EXPECT_NE(list.end(), list.find("testscopeC")); | 518 | EXPECT_NE(list.end(), list.find("testscopeC")); |
1144 | @@ -540,7 +556,7 @@ | |||
1145 | 540 | 556 | ||
1146 | 541 | // First check that we have 2 scopes registered | 557 | // First check that we have 2 scopes registered |
1147 | 542 | MetadataMap list = r->list(); | 558 | MetadataMap list = r->list(); |
1149 | 543 | EXPECT_EQ(2, list.size()); | 559 | EXPECT_EQ(2u, list.size()); |
1150 | 544 | EXPECT_NE(list.end(), list.find("testscopeA")); | 560 | EXPECT_NE(list.end(), list.find("testscopeA")); |
1151 | 545 | EXPECT_NE(list.end(), list.find("testscopeB")); | 561 | EXPECT_NE(list.end(), list.find("testscopeB")); |
1152 | 546 | EXPECT_EQ(list.end(), list.find("testscopeC")); | 562 | EXPECT_EQ(list.end(), list.find("testscopeC")); |
1153 | @@ -559,7 +575,7 @@ | |||
1154 | 559 | 575 | ||
1155 | 560 | // Now check that we have 3 scopes registered | 576 | // Now check that we have 3 scopes registered |
1156 | 561 | list = r->list(); | 577 | list = r->list(); |
1158 | 562 | EXPECT_EQ(3, list.size()); | 578 | EXPECT_EQ(3u, list.size()); |
1159 | 563 | EXPECT_NE(list.end(), list.find("testscopeA")); | 579 | EXPECT_NE(list.end(), list.find("testscopeA")); |
1160 | 564 | EXPECT_NE(list.end(), list.find("testscopeB")); | 580 | EXPECT_NE(list.end(), list.find("testscopeB")); |
1161 | 565 | EXPECT_NE(list.end(), list.find("testscopeC")); | 581 | EXPECT_NE(list.end(), list.find("testscopeC")); |
1162 | @@ -617,7 +633,7 @@ | |||
1163 | 617 | 633 | ||
1164 | 618 | // Now check that we have 3 scopes registered again | 634 | // Now check that we have 3 scopes registered again |
1165 | 619 | list = r->list(); | 635 | list = r->list(); |
1167 | 620 | EXPECT_EQ(3, list.size()); | 636 | EXPECT_EQ(3u, list.size()); |
1168 | 621 | EXPECT_NE(list.end(), list.find("testscopeA")); | 637 | EXPECT_NE(list.end(), list.find("testscopeA")); |
1169 | 622 | EXPECT_NE(list.end(), list.find("testscopeB")); | 638 | EXPECT_NE(list.end(), list.find("testscopeB")); |
1170 | 623 | EXPECT_EQ(list.end(), list.find("testscopeC")); | 639 | EXPECT_EQ(list.end(), list.find("testscopeC")); |
1171 | @@ -632,7 +648,7 @@ | |||
1172 | 632 | 648 | ||
1173 | 633 | // Now check that we are back to having 2 scopes registered | 649 | // Now check that we are back to having 2 scopes registered |
1174 | 634 | list = r->list(); | 650 | list = r->list(); |
1176 | 635 | EXPECT_EQ(2, list.size()); | 651 | EXPECT_EQ(2u, list.size()); |
1177 | 636 | EXPECT_NE(list.end(), list.find("testscopeA")); | 652 | EXPECT_NE(list.end(), list.find("testscopeA")); |
1178 | 637 | EXPECT_NE(list.end(), list.find("testscopeB")); | 653 | EXPECT_NE(list.end(), list.find("testscopeB")); |
1179 | 638 | EXPECT_EQ(list.end(), list.find("testscopeC")); | 654 | EXPECT_EQ(list.end(), list.find("testscopeC")); |
1180 | @@ -645,7 +661,7 @@ | |||
1181 | 645 | 661 | ||
1182 | 646 | // Check that no scopes were registered | 662 | // Check that no scopes were registered |
1183 | 647 | list = r->list(); | 663 | list = r->list(); |
1185 | 648 | EXPECT_EQ(2, list.size()); | 664 | EXPECT_EQ(2u, list.size()); |
1186 | 649 | EXPECT_NE(list.end(), list.find("testscopeA")); | 665 | EXPECT_NE(list.end(), list.find("testscopeA")); |
1187 | 650 | EXPECT_NE(list.end(), list.find("testscopeB")); | 666 | EXPECT_NE(list.end(), list.find("testscopeB")); |
1188 | 651 | EXPECT_EQ(list.end(), list.find("testscopeC")); | 667 | EXPECT_EQ(list.end(), list.find("testscopeC")); |
1189 | @@ -660,7 +676,7 @@ | |||
1190 | 660 | 676 | ||
1191 | 661 | // Now check that we have 3 scopes registered | 677 | // Now check that we have 3 scopes registered |
1192 | 662 | list = r->list(); | 678 | list = r->list(); |
1194 | 663 | EXPECT_EQ(3, list.size()); | 679 | EXPECT_EQ(3u, list.size()); |
1195 | 664 | EXPECT_NE(list.end(), list.find("testscopeA")); | 680 | EXPECT_NE(list.end(), list.find("testscopeA")); |
1196 | 665 | EXPECT_NE(list.end(), list.find("testscopeB")); | 681 | EXPECT_NE(list.end(), list.find("testscopeB")); |
1197 | 666 | EXPECT_NE(list.end(), list.find("testscopeC")); | 682 | EXPECT_NE(list.end(), list.find("testscopeC")); |
1198 | @@ -675,7 +691,7 @@ | |||
1199 | 675 | 691 | ||
1200 | 676 | // Now check that we are back to having 2 scopes registered | 692 | // Now check that we are back to having 2 scopes registered |
1201 | 677 | list = r->list(); | 693 | list = r->list(); |
1203 | 678 | EXPECT_EQ(2, list.size()); | 694 | EXPECT_EQ(2u, list.size()); |
1204 | 679 | EXPECT_NE(list.end(), list.find("testscopeA")); | 695 | EXPECT_NE(list.end(), list.find("testscopeA")); |
1205 | 680 | EXPECT_NE(list.end(), list.find("testscopeB")); | 696 | EXPECT_NE(list.end(), list.find("testscopeB")); |
1206 | 681 | EXPECT_EQ(list.end(), list.find("testscopeC")); | 697 | EXPECT_EQ(list.end(), list.find("testscopeC")); |
1207 | @@ -690,6 +706,7 @@ | |||
1208 | 690 | 706 | ||
1209 | 691 | // Unlink in case we left the link behind from an earlier interrupted run. | 707 | // Unlink in case we left the link behind from an earlier interrupted run. |
1210 | 692 | system::error_code ec; | 708 | system::error_code ec; |
1211 | 709 | filesystem::remove_all(TEST_RUNTIME_PATH "/applications", ec); | ||
1212 | 693 | filesystem::remove_all(TEST_RUNTIME_PATH "/scopes/testscopeC", ec); | 710 | filesystem::remove_all(TEST_RUNTIME_PATH "/scopes/testscopeC", ec); |
1213 | 694 | filesystem::remove_all(TEST_RUNTIME_PATH "/click",ec); | 711 | filesystem::remove_all(TEST_RUNTIME_PATH "/click",ec); |
1214 | 695 | filesystem::remove(TEST_RUNTIME_PATH "/scopes/testscopeD", ec); | 712 | filesystem::remove(TEST_RUNTIME_PATH "/scopes/testscopeD", ec); |
1215 | @@ -697,7 +714,7 @@ | |||
1216 | 697 | filesystem::remove(TEST_RUNTIME_PATH "/scopes/testscopeB/testscopeB-settings.ini", ec); | 714 | filesystem::remove(TEST_RUNTIME_PATH "/scopes/testscopeB/testscopeB-settings.ini", ec); |
1217 | 698 | 715 | ||
1218 | 699 | // Set the "TEST_DESKTOP_FILES_DIR" env var before forking as not to create desktop files in ~/.local | 716 | // Set the "TEST_DESKTOP_FILES_DIR" env var before forking as not to create desktop files in ~/.local |
1220 | 700 | putenv(const_cast<char*>("TEST_DESKTOP_FILES_DIR=" TEST_RUNTIME_PATH)); | 717 | putenv(const_cast<char*>("TEST_DESKTOP_FILES_DIR=" TEST_RUNTIME_PATH "/applications")); |
1221 | 701 | 718 | ||
1222 | 702 | auto rpid = fork(); | 719 | auto rpid = fork(); |
1223 | 703 | if (rpid == 0) | 720 | if (rpid == 0) |
1224 | 704 | 721 | ||
1225 | === modified file 'test/gtest/scopes/ReplyReaper/NoReplyScope.cpp' | |||
1226 | --- test/gtest/scopes/ReplyReaper/NoReplyScope.cpp 2014-07-29 05:50:14 +0000 | |||
1227 | +++ test/gtest/scopes/ReplyReaper/NoReplyScope.cpp 2017-01-16 06:43:13 +0000 | |||
1228 | @@ -22,7 +22,10 @@ | |||
1229 | 22 | 22 | ||
1230 | 23 | #include <thread> | 23 | #include <thread> |
1231 | 24 | 24 | ||
1232 | 25 | #pragma GCC diagnostic push | ||
1233 | 26 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1234 | 25 | #include <gtest/gtest.h> | 27 | #include <gtest/gtest.h> |
1235 | 28 | #pragma GCC diagnostic pop | ||
1236 | 26 | 29 | ||
1237 | 27 | using namespace std; | 30 | using namespace std; |
1238 | 28 | using namespace unity::scopes; | 31 | using namespace unity::scopes; |
1239 | 29 | 32 | ||
1240 | === modified file 'test/gtest/scopes/ReplyReaper/ReplyReaper_test.cpp' | |||
1241 | --- test/gtest/scopes/ReplyReaper/ReplyReaper_test.cpp 2015-01-09 03:16:51 +0000 | |||
1242 | +++ test/gtest/scopes/ReplyReaper/ReplyReaper_test.cpp 2017-01-16 06:43:13 +0000 | |||
1243 | @@ -21,7 +21,11 @@ | |||
1244 | 21 | #include <unity/scopes/internal/ScopeImpl.h> | 21 | #include <unity/scopes/internal/ScopeImpl.h> |
1245 | 22 | 22 | ||
1246 | 23 | #include <boost/algorithm/string.hpp> | 23 | #include <boost/algorithm/string.hpp> |
1247 | 24 | |||
1248 | 25 | #pragma GCC diagnostic push | ||
1249 | 26 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1250 | 24 | #include <gtest/gtest.h> | 27 | #include <gtest/gtest.h> |
1251 | 28 | #pragma GCC diagnostic pop | ||
1252 | 25 | 29 | ||
1253 | 26 | #include "NoReplyScope.h" | 30 | #include "NoReplyScope.h" |
1254 | 27 | #include <stdexcept> | 31 | #include <stdexcept> |
1255 | 28 | 32 | ||
1256 | === modified file 'test/gtest/scopes/ResultCache/ResultCache_test.cpp' | |||
1257 | --- test/gtest/scopes/ResultCache/ResultCache_test.cpp 2016-06-14 14:54:15 +0000 | |||
1258 | +++ test/gtest/scopes/ResultCache/ResultCache_test.cpp 2017-01-16 06:43:13 +0000 | |||
1259 | @@ -23,7 +23,12 @@ | |||
1260 | 23 | #include <unity/scopes/OptionSelectorFilter.h> | 23 | #include <unity/scopes/OptionSelectorFilter.h> |
1261 | 24 | 24 | ||
1262 | 25 | #include <boost/filesystem.hpp> | 25 | #include <boost/filesystem.hpp> |
1263 | 26 | |||
1264 | 27 | #pragma GCC diagnostic push | ||
1265 | 28 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1266 | 26 | #include <gtest/gtest.h> | 29 | #include <gtest/gtest.h> |
1267 | 30 | #pragma GCC diagnostic pop | ||
1268 | 31 | |||
1269 | 27 | #include <cstdint> | 32 | #include <cstdint> |
1270 | 28 | 33 | ||
1271 | 29 | #include "CacheScope.h" | 34 | #include "CacheScope.h" |
1272 | @@ -145,7 +150,7 @@ | |||
1273 | 145 | receiver->wait_until_finished(); | 150 | receiver->wait_until_finished(); |
1274 | 146 | 151 | ||
1275 | 147 | auto r = receiver->result(); | 152 | auto r = receiver->result(); |
1277 | 148 | EXPECT_EQ(r, nullptr); | 153 | EXPECT_EQ(nullptr, r); |
1278 | 149 | } | 154 | } |
1279 | 150 | 155 | ||
1280 | 151 | TEST_F(CacheScopeTest, non_surfacing_query) | 156 | TEST_F(CacheScopeTest, non_surfacing_query) |
1281 | @@ -157,11 +162,11 @@ | |||
1282 | 157 | receiver->wait_until_finished(); | 162 | receiver->wait_until_finished(); |
1283 | 158 | 163 | ||
1284 | 159 | auto r = receiver->result(); | 164 | auto r = receiver->result(); |
1286 | 160 | EXPECT_EQ(r->title(), "some query"); | 165 | EXPECT_EQ("some query", r->title()); |
1287 | 161 | auto d = receiver->dept(); | 166 | auto d = receiver->dept(); |
1289 | 162 | EXPECT_EQ(d->id(), ""); | 167 | EXPECT_EQ("", d->id()); |
1290 | 163 | auto sd = *d->subdepartments().begin(); | 168 | auto sd = *d->subdepartments().begin(); |
1292 | 164 | EXPECT_EQ(sd->id(), "subsome query"); | 169 | EXPECT_EQ("subsome query", sd->id()); |
1293 | 165 | 170 | ||
1294 | 166 | // Non-empty query, so there must be no cache file. | 171 | // Non-empty query, so there must be no cache file. |
1295 | 167 | boost::system::error_code ec; | 172 | boost::system::error_code ec; |
1296 | @@ -181,13 +186,13 @@ | |||
1297 | 181 | receiver->wait_until_finished(); | 186 | receiver->wait_until_finished(); |
1298 | 182 | 187 | ||
1299 | 183 | auto r = receiver->result(); | 188 | auto r = receiver->result(); |
1303 | 184 | EXPECT_EQ(r->title(), ""); | 189 | EXPECT_EQ("", r->title()); |
1304 | 185 | EXPECT_EQ(r->value("int64value").get_int64_t(), 1); | 190 | EXPECT_EQ(1, r->value("int64value").get_int64_t()); |
1305 | 186 | EXPECT_EQ(r->value("int64value2").get_int64_t(), INT64_MAX); | 191 | EXPECT_EQ(INT64_MAX, r->value("int64value2").get_int64_t()); |
1306 | 187 | auto d = receiver->dept(); | 192 | auto d = receiver->dept(); |
1308 | 188 | EXPECT_EQ(d->id(), ""); | 193 | EXPECT_EQ("", d->id()); |
1309 | 189 | auto sd = *d->subdepartments().begin(); | 194 | auto sd = *d->subdepartments().begin(); |
1311 | 190 | EXPECT_EQ(sd->id(), "sub"); | 195 | EXPECT_EQ("sub", sd->id()); |
1312 | 191 | 196 | ||
1313 | 192 | // Empty query, so there must be a cache file. | 197 | // Empty query, so there must be a cache file. |
1314 | 193 | boost::system::error_code ec; | 198 | boost::system::error_code ec; |
1315 | @@ -207,11 +212,11 @@ | |||
1316 | 207 | receiver->wait_until_finished(); | 212 | receiver->wait_until_finished(); |
1317 | 208 | 213 | ||
1318 | 209 | auto r = receiver->result(); | 214 | auto r = receiver->result(); |
1320 | 210 | EXPECT_EQ(r->title(), "some other query"); | 215 | EXPECT_EQ("some other query", r->title()); |
1321 | 211 | auto d = receiver->dept(); | 216 | auto d = receiver->dept(); |
1323 | 212 | EXPECT_EQ(d->id(), ""); | 217 | EXPECT_EQ("", d->id()); |
1324 | 213 | auto sd = *d->subdepartments().begin(); | 218 | auto sd = *d->subdepartments().begin(); |
1326 | 214 | EXPECT_EQ(sd->id(), "subsome other query"); | 219 | EXPECT_EQ("subsome other query", sd->id()); |
1327 | 215 | 220 | ||
1328 | 216 | // Cache file must still be there. | 221 | // Cache file must still be there. |
1329 | 217 | boost::system::error_code ec; | 222 | boost::system::error_code ec; |
1330 | @@ -225,15 +230,15 @@ | |||
1331 | 225 | receiver->wait_until_finished(); | 230 | receiver->wait_until_finished(); |
1332 | 226 | 231 | ||
1333 | 227 | auto r = receiver->result(); | 232 | auto r = receiver->result(); |
1337 | 228 | EXPECT_EQ(r->title(), ""); | 233 | EXPECT_EQ("", r->title()); |
1338 | 229 | EXPECT_EQ(r->value("int64value").get_int(), 1); | 234 | EXPECT_EQ(1, r->value("int64value").get_int()); |
1339 | 230 | EXPECT_EQ(r->value("int64value2").get_int64_t(), INT64_MAX); | 235 | EXPECT_EQ(INT64_MAX, r->value("int64value2").get_int64_t()); |
1340 | 231 | auto d = receiver->dept(); | 236 | auto d = receiver->dept(); |
1342 | 232 | EXPECT_EQ(d->id(), ""); | 237 | EXPECT_EQ("", d->id()); |
1343 | 233 | auto sd = *d->subdepartments().begin(); | 238 | auto sd = *d->subdepartments().begin(); |
1345 | 234 | EXPECT_EQ(sd->id(), "sub"); | 239 | EXPECT_EQ("sub", sd->id()); |
1346 | 235 | auto filters = receiver->filters(); | 240 | auto filters = receiver->filters(); |
1348 | 236 | ASSERT_EQ(1, filters.size()); | 241 | ASSERT_EQ(1u, filters.size()); |
1349 | 237 | auto f = *filters.begin(); | 242 | auto f = *filters.begin(); |
1350 | 238 | EXPECT_EQ("option_selector", f->filter_type()); | 243 | EXPECT_EQ("option_selector", f->filter_type()); |
1351 | 239 | EXPECT_EQ(nullptr, f->filter_group()); | 244 | EXPECT_EQ(nullptr, f->filter_group()); |
1352 | @@ -262,15 +267,15 @@ | |||
1353 | 262 | 267 | ||
1354 | 263 | auto r = receiver->result(); | 268 | auto r = receiver->result(); |
1355 | 264 | ASSERT_TRUE(r != nullptr); | 269 | ASSERT_TRUE(r != nullptr); |
1359 | 265 | EXPECT_EQ(r->title(), ""); | 270 | EXPECT_EQ("", r->title()); |
1360 | 266 | EXPECT_EQ(r->value("int64value").get_int(), 1); | 271 | EXPECT_EQ(1, r->value("int64value").get_int()); |
1361 | 267 | EXPECT_EQ(r->value("int64value2").get_int64_t(), INT64_MAX); | 272 | EXPECT_EQ(INT64_MAX, r->value("int64value2").get_int64_t()); |
1362 | 268 | auto d = receiver->dept(); | 273 | auto d = receiver->dept(); |
1364 | 269 | EXPECT_EQ(d->id(), ""); | 274 | EXPECT_EQ("", d->id()); |
1365 | 270 | auto sd = *d->subdepartments().begin(); | 275 | auto sd = *d->subdepartments().begin(); |
1367 | 271 | EXPECT_EQ(sd->id(), "sub"); | 276 | EXPECT_EQ("sub", sd->id()); |
1368 | 272 | auto filters = receiver->filters(); | 277 | auto filters = receiver->filters(); |
1370 | 273 | ASSERT_EQ(1, filters.size()); | 278 | ASSERT_EQ(1u, filters.size()); |
1371 | 274 | auto f = *filters.begin(); | 279 | auto f = *filters.begin(); |
1372 | 275 | EXPECT_EQ("option_selector", f->filter_type()); | 280 | EXPECT_EQ("option_selector", f->filter_type()); |
1373 | 276 | ASSERT_TRUE(f->filter_group() != nullptr); | 281 | ASSERT_TRUE(f->filter_group() != nullptr); |
1374 | @@ -317,14 +322,14 @@ | |||
1375 | 317 | receiver->wait_until_finished(); | 322 | receiver->wait_until_finished(); |
1376 | 318 | 323 | ||
1377 | 319 | auto r = receiver->result(); | 324 | auto r = receiver->result(); |
1380 | 320 | EXPECT_EQ(r->title(), ""); | 325 | EXPECT_EQ("", r->title()); |
1381 | 321 | EXPECT_EQ(r->value("int64value").get_int64_t(), 1); | 326 | EXPECT_EQ(1, r->value("int64value").get_int64_t()); |
1382 | 322 | auto d = receiver->dept(); | 327 | auto d = receiver->dept(); |
1384 | 323 | EXPECT_EQ(d->id(), ""); | 328 | EXPECT_EQ("", d->id()); |
1385 | 324 | auto sd = *d->subdepartments().begin(); | 329 | auto sd = *d->subdepartments().begin(); |
1387 | 325 | EXPECT_EQ(sd->id(), "sub"); | 330 | EXPECT_EQ("sub", sd->id()); |
1388 | 326 | auto filters = receiver->filters(); | 331 | auto filters = receiver->filters(); |
1390 | 327 | ASSERT_EQ(1, filters.size()); | 332 | ASSERT_EQ(1u, filters.size()); |
1391 | 328 | auto f = *filters.begin(); | 333 | auto f = *filters.begin(); |
1392 | 329 | EXPECT_EQ("option_selector", f->filter_type()); | 334 | EXPECT_EQ("option_selector", f->filter_type()); |
1393 | 330 | auto osf = dynamic_pointer_cast<OptionSelectorFilter const>(f); | 335 | auto osf = dynamic_pointer_cast<OptionSelectorFilter const>(f); |
1394 | @@ -342,7 +347,7 @@ | |||
1395 | 342 | auto receiver = make_shared<Receiver>(); | 347 | auto receiver = make_shared<Receiver>(); |
1396 | 343 | scope()->search("", SearchMetadata("unused", "unused"), receiver); | 348 | scope()->search("", SearchMetadata("unused", "unused"), receiver); |
1397 | 344 | receiver->wait_until_finished(); | 349 | receiver->wait_until_finished(); |
1399 | 345 | EXPECT_EQ(receiver->result(), nullptr); | 350 | EXPECT_EQ(nullptr, receiver->result()); |
1400 | 346 | ::chmod(TEST_RUNTIME_PATH "/unconfined/CacheScope/.surfacing_cache", 0600); | 351 | ::chmod(TEST_RUNTIME_PATH "/unconfined/CacheScope/.surfacing_cache", 0600); |
1401 | 347 | 352 | ||
1402 | 348 | // Cache file must still be there, but read will have failed. | 353 | // Cache file must still be there, but read will have failed. |
1403 | @@ -362,7 +367,7 @@ | |||
1404 | 362 | auto receiver = make_shared<Receiver>(); | 367 | auto receiver = make_shared<Receiver>(); |
1405 | 363 | scope()->search("", SearchMetadata("unused", "unused"), receiver); | 368 | scope()->search("", SearchMetadata("unused", "unused"), receiver); |
1406 | 364 | receiver->wait_until_finished(); | 369 | receiver->wait_until_finished(); |
1408 | 365 | EXPECT_EQ(receiver->result(), nullptr); | 370 | EXPECT_EQ(nullptr, receiver->result()); |
1409 | 366 | 371 | ||
1410 | 367 | // Cache file must still be there, but decode will have failed. | 372 | // Cache file must still be there, but decode will have failed. |
1411 | 368 | boost::system::error_code ec; | 373 | boost::system::error_code ec; |
1412 | @@ -376,7 +381,7 @@ | |||
1413 | 376 | auto receiver = make_shared<Receiver>(); | 381 | auto receiver = make_shared<Receiver>(); |
1414 | 377 | scope()->search("", SearchMetadata("unused", "unused"), receiver); | 382 | scope()->search("", SearchMetadata("unused", "unused"), receiver); |
1415 | 378 | receiver->wait_until_finished(); | 383 | receiver->wait_until_finished(); |
1417 | 379 | EXPECT_EQ(receiver->result(), nullptr); | 384 | EXPECT_EQ(nullptr, receiver->result()); |
1418 | 380 | 385 | ||
1419 | 381 | // Cache file must still be there, but decode will have failed. | 386 | // Cache file must still be there, but decode will have failed. |
1420 | 382 | boost::system::error_code ec; | 387 | boost::system::error_code ec; |
1421 | @@ -390,7 +395,7 @@ | |||
1422 | 390 | auto receiver = make_shared<Receiver>(); | 395 | auto receiver = make_shared<Receiver>(); |
1423 | 391 | scope()->search("", SearchMetadata("unused", "unused"), receiver); | 396 | scope()->search("", SearchMetadata("unused", "unused"), receiver); |
1424 | 392 | receiver->wait_until_finished(); | 397 | receiver->wait_until_finished(); |
1426 | 393 | EXPECT_EQ(receiver->result(), nullptr); | 398 | EXPECT_EQ(nullptr, receiver->result()); |
1427 | 394 | 399 | ||
1428 | 395 | // Cache file must still be there, but decode will have failed. | 400 | // Cache file must still be there, but decode will have failed. |
1429 | 396 | boost::system::error_code ec; | 401 | boost::system::error_code ec; |
1430 | @@ -404,7 +409,7 @@ | |||
1431 | 404 | auto receiver = make_shared<Receiver>(); | 409 | auto receiver = make_shared<Receiver>(); |
1432 | 405 | scope()->search("", SearchMetadata("unused", "unused"), receiver); | 410 | scope()->search("", SearchMetadata("unused", "unused"), receiver); |
1433 | 406 | receiver->wait_until_finished(); | 411 | receiver->wait_until_finished(); |
1435 | 407 | EXPECT_EQ(receiver->result(), nullptr); | 412 | EXPECT_EQ(nullptr, receiver->result()); |
1436 | 408 | 413 | ||
1437 | 409 | // Cache file must still be there, but decode will have failed. | 414 | // Cache file must still be there, but decode will have failed. |
1438 | 410 | boost::system::error_code ec; | 415 | boost::system::error_code ec; |
1439 | 411 | 416 | ||
1440 | === modified file 'test/gtest/scopes/Runtime/PusherScope.cpp' | |||
1441 | --- test/gtest/scopes/Runtime/PusherScope.cpp 2014-07-30 20:39:04 +0000 | |||
1442 | +++ test/gtest/scopes/Runtime/PusherScope.cpp 2017-01-16 06:43:13 +0000 | |||
1443 | @@ -25,7 +25,10 @@ | |||
1444 | 25 | 25 | ||
1445 | 26 | #include <atomic> | 26 | #include <atomic> |
1446 | 27 | 27 | ||
1447 | 28 | #pragma GCC diagnostic push | ||
1448 | 29 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1449 | 28 | #include <gtest/gtest.h> | 30 | #include <gtest/gtest.h> |
1450 | 31 | #pragma GCC diagnostic pop | ||
1451 | 29 | 32 | ||
1452 | 30 | using namespace std; | 33 | using namespace std; |
1453 | 31 | using namespace unity::scopes; | 34 | using namespace unity::scopes; |
1454 | 32 | 35 | ||
1455 | === modified file 'test/gtest/scopes/Runtime/Runtime_test.cpp' | |||
1456 | --- test/gtest/scopes/Runtime/Runtime_test.cpp 2015-01-09 03:16:51 +0000 | |||
1457 | +++ test/gtest/scopes/Runtime/Runtime_test.cpp 2017-01-16 06:43:13 +0000 | |||
1458 | @@ -28,7 +28,10 @@ | |||
1459 | 28 | #include <unity/scopes/SearchMetadata.h> | 28 | #include <unity/scopes/SearchMetadata.h> |
1460 | 29 | #include <unity/UnityExceptions.h> | 29 | #include <unity/UnityExceptions.h> |
1461 | 30 | 30 | ||
1462 | 31 | #pragma GCC diagnostic push | ||
1463 | 32 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1464 | 31 | #include <gtest/gtest.h> | 33 | #include <gtest/gtest.h> |
1465 | 34 | #pragma GCC diagnostic pop | ||
1466 | 32 | 35 | ||
1467 | 33 | #include "PusherScope.h" | 36 | #include "PusherScope.h" |
1468 | 34 | #include "SlowCreateScope.h" | 37 | #include "SlowCreateScope.h" |
1469 | @@ -113,7 +116,7 @@ | |||
1470 | 113 | EXPECT_EQ(1, annotation_count_); | 116 | EXPECT_EQ(1, annotation_count_); |
1471 | 114 | EXPECT_EQ(2, info_count_); | 117 | EXPECT_EQ(2, info_count_); |
1472 | 115 | 118 | ||
1474 | 116 | EXPECT_EQ(2, details.info_list().size()); | 119 | EXPECT_EQ(2u, details.info_list().size()); |
1475 | 117 | if (details.info_list().size() == 2) | 120 | if (details.info_list().size() == 2) |
1476 | 118 | { | 121 | { |
1477 | 119 | EXPECT_EQ(OperationInfo::NoInternet, details.info_list()[0].code()); | 122 | EXPECT_EQ(OperationInfo::NoInternet, details.info_list()[0].code()); |
1478 | @@ -201,7 +204,7 @@ | |||
1479 | 201 | EXPECT_EQ(2, data_pushes_); | 204 | EXPECT_EQ(2, data_pushes_); |
1480 | 202 | EXPECT_EQ(2, info_count_); | 205 | EXPECT_EQ(2, info_count_); |
1481 | 203 | 206 | ||
1483 | 204 | EXPECT_EQ(2, details.info_list().size()); | 207 | EXPECT_EQ(2u, details.info_list().size()); |
1484 | 205 | if (details.info_list().size() == 2) | 208 | if (details.info_list().size() == 2) |
1485 | 206 | { | 209 | { |
1486 | 207 | EXPECT_EQ(OperationInfo::NoLocationData, details.info_list()[0].code()); | 210 | EXPECT_EQ(OperationInfo::NoLocationData, details.info_list()[0].code()); |
1487 | 208 | 211 | ||
1488 | === modified file 'test/gtest/scopes/Runtime/SlowCreateScope.cpp' | |||
1489 | --- test/gtest/scopes/Runtime/SlowCreateScope.cpp 2014-09-08 05:55:39 +0000 | |||
1490 | +++ test/gtest/scopes/Runtime/SlowCreateScope.cpp 2017-01-16 06:43:13 +0000 | |||
1491 | @@ -24,7 +24,10 @@ | |||
1492 | 24 | #include <mutex> | 24 | #include <mutex> |
1493 | 25 | #include <thread> | 25 | #include <thread> |
1494 | 26 | 26 | ||
1495 | 27 | #pragma GCC diagnostic push | ||
1496 | 28 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1497 | 27 | #include <gtest/gtest.h> | 29 | #include <gtest/gtest.h> |
1498 | 30 | #pragma GCC diagnostic pop | ||
1499 | 28 | 31 | ||
1500 | 29 | using namespace std; | 32 | using namespace std; |
1501 | 30 | using namespace unity::scopes; | 33 | using namespace unity::scopes; |
1502 | 31 | 34 | ||
1503 | === modified file 'test/gtest/scopes/Runtime/TestScope.cpp' | |||
1504 | --- test/gtest/scopes/Runtime/TestScope.cpp 2014-07-30 20:39:04 +0000 | |||
1505 | +++ test/gtest/scopes/Runtime/TestScope.cpp 2017-01-16 06:43:13 +0000 | |||
1506 | @@ -25,7 +25,11 @@ | |||
1507 | 25 | #include <unity/scopes/ScopeBase.h> | 25 | #include <unity/scopes/ScopeBase.h> |
1508 | 26 | #include <unity/scopes/SearchReply.h> | 26 | #include <unity/scopes/SearchReply.h> |
1509 | 27 | #include <unity/UnityExceptions.h> | 27 | #include <unity/UnityExceptions.h> |
1510 | 28 | |||
1511 | 29 | #pragma GCC diagnostic push | ||
1512 | 30 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1513 | 28 | #include <gtest/gtest.h> | 31 | #include <gtest/gtest.h> |
1514 | 32 | #pragma GCC diagnostic pop | ||
1515 | 29 | 33 | ||
1516 | 30 | #include "TestScope.h" | 34 | #include "TestScope.h" |
1517 | 31 | 35 | ||
1518 | 32 | 36 | ||
1519 | === modified file 'test/gtest/scopes/ScopeBase/ScopeBase_test.cpp' | |||
1520 | --- test/gtest/scopes/ScopeBase/ScopeBase_test.cpp 2014-07-10 06:39:03 +0000 | |||
1521 | +++ test/gtest/scopes/ScopeBase/ScopeBase_test.cpp 2017-01-16 06:43:13 +0000 | |||
1522 | @@ -20,7 +20,10 @@ | |||
1523 | 20 | #include <unity/scopes/internal/DynamicLoader.h> | 20 | #include <unity/scopes/internal/DynamicLoader.h> |
1524 | 21 | #include <unity/UnityExceptions.h> | 21 | #include <unity/UnityExceptions.h> |
1525 | 22 | 22 | ||
1526 | 23 | #pragma GCC diagnostic push | ||
1527 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1528 | 23 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
1529 | 26 | #pragma GCC diagnostic pop | ||
1530 | 24 | 27 | ||
1531 | 25 | using namespace unity::scopes; | 28 | using namespace unity::scopes; |
1532 | 26 | using namespace unity::scopes::internal; | 29 | using namespace unity::scopes::internal; |
1533 | 27 | 30 | ||
1534 | === modified file 'test/gtest/scopes/ScopeExceptions/ScopeExceptions_test.cpp' | |||
1535 | --- test/gtest/scopes/ScopeExceptions/ScopeExceptions_test.cpp 2014-04-17 01:36:29 +0000 | |||
1536 | +++ test/gtest/scopes/ScopeExceptions/ScopeExceptions_test.cpp 2017-01-16 06:43:13 +0000 | |||
1537 | @@ -18,7 +18,10 @@ | |||
1538 | 18 | 18 | ||
1539 | 19 | #include <unity/scopes/ScopeExceptions.h> | 19 | #include <unity/scopes/ScopeExceptions.h> |
1540 | 20 | 20 | ||
1541 | 21 | #pragma GCC diagnostic push | ||
1542 | 22 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1543 | 21 | #include <gtest/gtest.h> | 23 | #include <gtest/gtest.h> |
1544 | 24 | #pragma GCC diagnostic pop | ||
1545 | 22 | 25 | ||
1546 | 23 | using namespace std; | 26 | using namespace std; |
1547 | 24 | using namespace unity::scopes; | 27 | using namespace unity::scopes; |
1548 | 25 | 28 | ||
1549 | === modified file 'test/gtest/scopes/StandAloneScope/StandAloneScope_test.cpp' | |||
1550 | --- test/gtest/scopes/StandAloneScope/StandAloneScope_test.cpp 2015-08-05 05:59:00 +0000 | |||
1551 | +++ test/gtest/scopes/StandAloneScope/StandAloneScope_test.cpp 2017-01-16 06:43:13 +0000 | |||
1552 | @@ -22,7 +22,10 @@ | |||
1553 | 22 | #include <unity/scopes/SearchListenerBase.h> | 22 | #include <unity/scopes/SearchListenerBase.h> |
1554 | 23 | #include <unity/scopes/SearchMetadata.h> | 23 | #include <unity/scopes/SearchMetadata.h> |
1555 | 24 | 24 | ||
1556 | 25 | #pragma GCC diagnostic push | ||
1557 | 26 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1558 | 25 | #include <gtest/gtest.h> | 27 | #include <gtest/gtest.h> |
1559 | 28 | #pragma GCC diagnostic pop | ||
1560 | 26 | 29 | ||
1561 | 27 | #include <chrono> | 30 | #include <chrono> |
1562 | 28 | #include <condition_variable> | 31 | #include <condition_variable> |
1563 | 29 | 32 | ||
1564 | === modified file 'test/gtest/scopes/StripLocation/StripLocation_test.cpp' | |||
1565 | --- test/gtest/scopes/StripLocation/StripLocation_test.cpp 2015-03-02 07:04:42 +0000 | |||
1566 | +++ test/gtest/scopes/StripLocation/StripLocation_test.cpp 2017-01-16 06:43:13 +0000 | |||
1567 | @@ -20,7 +20,10 @@ | |||
1568 | 20 | #include <unity/scopes/internal/RuntimeImpl.h> | 20 | #include <unity/scopes/internal/RuntimeImpl.h> |
1569 | 21 | #include <unity/scopes/SearchMetadata.h> | 21 | #include <unity/scopes/SearchMetadata.h> |
1570 | 22 | 22 | ||
1571 | 23 | #pragma GCC diagnostic push | ||
1572 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1573 | 23 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
1574 | 26 | #pragma GCC diagnostic pop | ||
1575 | 24 | 27 | ||
1576 | 25 | using namespace std; | 28 | using namespace std; |
1577 | 26 | using namespace unity::scopes; | 29 | using namespace unity::scopes; |
1578 | 27 | 30 | ||
1579 | === modified file 'test/gtest/scopes/SwitchFilter/SwitchFilter_test.cpp' | |||
1580 | --- test/gtest/scopes/SwitchFilter/SwitchFilter_test.cpp 2015-11-12 12:45:41 +0000 | |||
1581 | +++ test/gtest/scopes/SwitchFilter/SwitchFilter_test.cpp 2017-01-16 06:43:13 +0000 | |||
1582 | @@ -16,7 +16,11 @@ | |||
1583 | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> |
1584 | 17 | */ | 17 | */ |
1585 | 18 | 18 | ||
1586 | 19 | #pragma GCC diagnostic push | ||
1587 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1588 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
1589 | 22 | #pragma GCC diagnostic pop | ||
1590 | 23 | |||
1591 | 20 | #include <unity/scopes/FilterState.h> | 24 | #include <unity/scopes/FilterState.h> |
1592 | 21 | #include <unity/scopes/SwitchFilter.h> | 25 | #include <unity/scopes/SwitchFilter.h> |
1593 | 22 | #include <unity/scopes/internal/SwitchFilterImpl.h> | 26 | #include <unity/scopes/internal/SwitchFilterImpl.h> |
1594 | 23 | 27 | ||
1595 | === modified file 'test/gtest/scopes/ThrowingClient/ThrowingClient_test.cpp' | |||
1596 | --- test/gtest/scopes/ThrowingClient/ThrowingClient_test.cpp 2015-11-26 05:48:01 +0000 | |||
1597 | +++ test/gtest/scopes/ThrowingClient/ThrowingClient_test.cpp 2017-01-16 06:43:13 +0000 | |||
1598 | @@ -21,7 +21,10 @@ | |||
1599 | 21 | 21 | ||
1600 | 22 | #include <unity/UnityExceptions.h> | 22 | #include <unity/UnityExceptions.h> |
1601 | 23 | 23 | ||
1602 | 24 | #pragma GCC diagnostic push | ||
1603 | 25 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1604 | 24 | #include <gtest/gtest.h> | 26 | #include <gtest/gtest.h> |
1605 | 27 | #pragma GCC diagnostic pop | ||
1606 | 25 | 28 | ||
1607 | 26 | #include <condition_variable> | 29 | #include <condition_variable> |
1608 | 27 | 30 | ||
1609 | @@ -325,7 +328,7 @@ | |||
1610 | 325 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 328 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1611 | 326 | EXPECT_EQ("", receiver->completion_msg()); | 329 | EXPECT_EQ("", receiver->completion_msg()); |
1612 | 327 | auto r = receiver->results(); | 330 | auto r = receiver->results(); |
1614 | 328 | ASSERT_EQ(1, r.size()); | 331 | ASSERT_EQ(1u, r.size()); |
1615 | 329 | EXPECT_EQ("success", r[0].title()); | 332 | EXPECT_EQ("success", r[0].title()); |
1616 | 330 | } | 333 | } |
1617 | 331 | 334 | ||
1618 | @@ -413,7 +416,7 @@ | |||
1619 | 413 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 416 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1620 | 414 | EXPECT_EQ("", receiver->completion_msg()); | 417 | EXPECT_EQ("", receiver->completion_msg()); |
1621 | 415 | auto r = receiver->results(); | 418 | auto r = receiver->results(); |
1623 | 416 | ASSERT_EQ(1, r.size()); | 419 | ASSERT_EQ(1u, r.size()); |
1624 | 417 | EXPECT_EQ(r[0].title(), "success"); | 420 | EXPECT_EQ(r[0].title(), "success"); |
1625 | 418 | 421 | ||
1626 | 419 | auto plistener = make_shared<PreviewListener>(); | 422 | auto plistener = make_shared<PreviewListener>(); |
1627 | @@ -433,7 +436,7 @@ | |||
1628 | 433 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 436 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1629 | 434 | EXPECT_EQ("", receiver->completion_msg()); | 437 | EXPECT_EQ("", receiver->completion_msg()); |
1630 | 435 | auto r = receiver->results(); | 438 | auto r = receiver->results(); |
1632 | 436 | ASSERT_EQ(1, r.size()); | 439 | ASSERT_EQ(1u, r.size()); |
1633 | 437 | EXPECT_EQ(r[0].title(), "success"); | 440 | EXPECT_EQ(r[0].title(), "success"); |
1634 | 438 | 441 | ||
1635 | 439 | auto plistener = make_shared<PreviewListener>("throw from preview push layout"); | 442 | auto plistener = make_shared<PreviewListener>("throw from preview push layout"); |
1636 | @@ -454,7 +457,7 @@ | |||
1637 | 454 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 457 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1638 | 455 | EXPECT_EQ("", receiver->completion_msg()); | 458 | EXPECT_EQ("", receiver->completion_msg()); |
1639 | 456 | auto r = receiver->results(); | 459 | auto r = receiver->results(); |
1641 | 457 | ASSERT_EQ(1, r.size()); | 460 | ASSERT_EQ(1u, r.size()); |
1642 | 458 | EXPECT_EQ(r[0].title(), "success"); | 461 | EXPECT_EQ(r[0].title(), "success"); |
1643 | 459 | 462 | ||
1644 | 460 | auto plistener = make_shared<PreviewListener>("throw from preview push widget"); | 463 | auto plistener = make_shared<PreviewListener>("throw from preview push widget"); |
1645 | @@ -475,7 +478,7 @@ | |||
1646 | 475 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 478 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1647 | 476 | EXPECT_EQ("", receiver->completion_msg()); | 479 | EXPECT_EQ("", receiver->completion_msg()); |
1648 | 477 | auto r = receiver->results(); | 480 | auto r = receiver->results(); |
1650 | 478 | ASSERT_EQ(1, r.size()); | 481 | ASSERT_EQ(1u, r.size()); |
1651 | 479 | EXPECT_EQ(r[0].title(), "success"); | 482 | EXPECT_EQ(r[0].title(), "success"); |
1652 | 480 | 483 | ||
1653 | 481 | auto plistener = make_shared<PreviewListener>("throw from preview push attribute"); | 484 | auto plistener = make_shared<PreviewListener>("throw from preview push attribute"); |
1654 | @@ -496,7 +499,7 @@ | |||
1655 | 496 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 499 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1656 | 497 | EXPECT_EQ("", receiver->completion_msg()); | 500 | EXPECT_EQ("", receiver->completion_msg()); |
1657 | 498 | auto r = receiver->results(); | 501 | auto r = receiver->results(); |
1659 | 499 | ASSERT_EQ(1, r.size()); | 502 | ASSERT_EQ(1u, r.size()); |
1660 | 500 | EXPECT_EQ(r[0].title(), "success"); | 503 | EXPECT_EQ(r[0].title(), "success"); |
1661 | 501 | 504 | ||
1662 | 502 | auto plistener = make_shared<PreviewListener>("throw from preview finished"); | 505 | auto plistener = make_shared<PreviewListener>("throw from preview finished"); |
1663 | @@ -516,7 +519,7 @@ | |||
1664 | 516 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 519 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1665 | 517 | EXPECT_EQ("", receiver->completion_msg()); | 520 | EXPECT_EQ("", receiver->completion_msg()); |
1666 | 518 | auto r = receiver->results(); | 521 | auto r = receiver->results(); |
1668 | 519 | ASSERT_EQ(1, r.size()); | 522 | ASSERT_EQ(1u, r.size()); |
1669 | 520 | EXPECT_EQ(r[0].title(), "success"); | 523 | EXPECT_EQ(r[0].title(), "success"); |
1670 | 521 | 524 | ||
1671 | 522 | auto alistener = make_shared<ActivationListener>(); | 525 | auto alistener = make_shared<ActivationListener>(); |
1672 | @@ -536,7 +539,7 @@ | |||
1673 | 536 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 539 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1674 | 537 | EXPECT_EQ("", receiver->completion_msg()); | 540 | EXPECT_EQ("", receiver->completion_msg()); |
1675 | 538 | auto r = receiver->results(); | 541 | auto r = receiver->results(); |
1677 | 539 | ASSERT_EQ(1, r.size()); | 542 | ASSERT_EQ(1u, r.size()); |
1678 | 540 | EXPECT_EQ(r[0].title(), "success"); | 543 | EXPECT_EQ(r[0].title(), "success"); |
1679 | 541 | 544 | ||
1680 | 542 | auto alistener = make_shared<ActivationListener>("throw from activation activate"); | 545 | auto alistener = make_shared<ActivationListener>("throw from activation activate"); |
1681 | @@ -557,7 +560,7 @@ | |||
1682 | 557 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 560 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1683 | 558 | EXPECT_EQ("", receiver->completion_msg()); | 561 | EXPECT_EQ("", receiver->completion_msg()); |
1684 | 559 | auto r = receiver->results(); | 562 | auto r = receiver->results(); |
1686 | 560 | ASSERT_EQ(1, r.size()); | 563 | ASSERT_EQ(1u, r.size()); |
1687 | 561 | EXPECT_EQ(r[0].title(), "success"); | 564 | EXPECT_EQ(r[0].title(), "success"); |
1688 | 562 | 565 | ||
1689 | 563 | auto alistener = make_shared<ActivationListener>("throw from activation finished"); | 566 | auto alistener = make_shared<ActivationListener>("throw from activation finished"); |
1690 | 564 | 567 | ||
1691 | === modified file 'test/gtest/scopes/ThrowingScope/ThrowingScope_test.cpp' | |||
1692 | --- test/gtest/scopes/ThrowingScope/ThrowingScope_test.cpp 2015-02-06 06:33:23 +0000 | |||
1693 | +++ test/gtest/scopes/ThrowingScope/ThrowingScope_test.cpp 2017-01-16 06:43:13 +0000 | |||
1694 | @@ -20,7 +20,10 @@ | |||
1695 | 20 | #include <unity/scopes/QueryCtrl.h> | 20 | #include <unity/scopes/QueryCtrl.h> |
1696 | 21 | #include <unity/scopes/Runtime.h> | 21 | #include <unity/scopes/Runtime.h> |
1697 | 22 | 22 | ||
1698 | 23 | #pragma GCC diagnostic push | ||
1699 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1700 | 23 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
1701 | 26 | #pragma GCC diagnostic pop | ||
1702 | 24 | 27 | ||
1703 | 25 | #include <condition_variable> | 28 | #include <condition_variable> |
1704 | 26 | #include <thread> | 29 | #include <thread> |
1705 | @@ -240,7 +243,7 @@ | |||
1706 | 240 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 243 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1707 | 241 | EXPECT_EQ("", receiver->completion_msg()); | 244 | EXPECT_EQ("", receiver->completion_msg()); |
1708 | 242 | auto r = receiver->results(); | 245 | auto r = receiver->results(); |
1710 | 243 | EXPECT_EQ(1, r.size()); | 246 | EXPECT_EQ(1u, r.size()); |
1711 | 244 | } | 247 | } |
1712 | 245 | 248 | ||
1713 | 246 | TEST_F(ThrowingScopeTest, throw_from_search) | 249 | TEST_F(ThrowingScopeTest, throw_from_search) |
1714 | @@ -255,7 +258,7 @@ | |||
1715 | 255 | " unity::ResourceException: exception from search", | 258 | " unity::ResourceException: exception from search", |
1716 | 256 | receiver->completion_msg()); | 259 | receiver->completion_msg()); |
1717 | 257 | auto r = receiver->results(); | 260 | auto r = receiver->results(); |
1719 | 258 | EXPECT_EQ(0, r.size()); | 261 | EXPECT_EQ(0u, r.size()); |
1720 | 259 | } | 262 | } |
1721 | 260 | 263 | ||
1722 | 261 | TEST_F(ThrowingScopeTest, throw_from_run) | 264 | TEST_F(ThrowingScopeTest, throw_from_run) |
1723 | @@ -267,7 +270,7 @@ | |||
1724 | 267 | EXPECT_EQ(CompletionDetails::CompletionStatus::Error, receiver->completion_status()); | 270 | EXPECT_EQ(CompletionDetails::CompletionStatus::Error, receiver->completion_status()); |
1725 | 268 | EXPECT_EQ("QueryBase::run(): unity::ResourceException: exception from run", receiver->completion_msg()); | 271 | EXPECT_EQ("QueryBase::run(): unity::ResourceException: exception from run", receiver->completion_msg()); |
1726 | 269 | auto r = receiver->results(); | 272 | auto r = receiver->results(); |
1728 | 270 | EXPECT_EQ(0, r.size()); | 273 | EXPECT_EQ(0u, r.size()); |
1729 | 271 | } | 274 | } |
1730 | 272 | 275 | ||
1731 | 273 | TEST_F(ThrowingScopeTest, throw_from_cancelled) | 276 | TEST_F(ThrowingScopeTest, throw_from_cancelled) |
1732 | @@ -280,7 +283,7 @@ | |||
1733 | 280 | receiver->wait_until_finished(); | 283 | receiver->wait_until_finished(); |
1734 | 281 | 284 | ||
1735 | 282 | auto r = receiver->results(); | 285 | auto r = receiver->results(); |
1737 | 283 | EXPECT_EQ(0, r.size()); | 286 | EXPECT_EQ(0u, r.size()); |
1738 | 284 | 287 | ||
1739 | 285 | EXPECT_EQ(CompletionDetails::CompletionStatus::Cancelled, receiver->completion_status()); | 288 | EXPECT_EQ(CompletionDetails::CompletionStatus::Cancelled, receiver->completion_status()); |
1740 | 286 | // No exception string here because we short-cut the cancellation on the client side. | 289 | // No exception string here because we short-cut the cancellation on the client side. |
1741 | @@ -297,7 +300,7 @@ | |||
1742 | 297 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 300 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1743 | 298 | EXPECT_EQ("", receiver->completion_msg()); | 301 | EXPECT_EQ("", receiver->completion_msg()); |
1744 | 299 | auto r = receiver->results(); | 302 | auto r = receiver->results(); |
1746 | 300 | EXPECT_EQ(1, r.size()); | 303 | EXPECT_EQ(1u, r.size()); |
1747 | 301 | 304 | ||
1748 | 302 | auto plistener = make_shared<PreviewListener>(); | 305 | auto plistener = make_shared<PreviewListener>(); |
1749 | 303 | scope()->preview(r[0], ActionMetadata("unused", "unused"), plistener); | 306 | scope()->preview(r[0], ActionMetadata("unused", "unused"), plistener); |
1750 | @@ -319,7 +322,7 @@ | |||
1751 | 319 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 322 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1752 | 320 | EXPECT_EQ("", receiver->completion_msg()); | 323 | EXPECT_EQ("", receiver->completion_msg()); |
1753 | 321 | auto r = receiver->results(); | 324 | auto r = receiver->results(); |
1755 | 322 | EXPECT_EQ(1, r.size()); | 325 | EXPECT_EQ(1u, r.size()); |
1756 | 323 | 326 | ||
1757 | 324 | auto plistener = make_shared<PreviewListener>(); | 327 | auto plistener = make_shared<PreviewListener>(); |
1758 | 325 | scope()->preview(r[0], ActionMetadata("unused", "unused"), plistener); | 328 | scope()->preview(r[0], ActionMetadata("unused", "unused"), plistener); |
1759 | @@ -338,7 +341,7 @@ | |||
1760 | 338 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 341 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1761 | 339 | EXPECT_EQ("", receiver->completion_msg()); | 342 | EXPECT_EQ("", receiver->completion_msg()); |
1762 | 340 | auto r = receiver->results(); | 343 | auto r = receiver->results(); |
1764 | 341 | EXPECT_EQ(1, r.size()); | 344 | EXPECT_EQ(1u, r.size()); |
1765 | 342 | 345 | ||
1766 | 343 | auto plistener = make_shared<PreviewListener>(); | 346 | auto plistener = make_shared<PreviewListener>(); |
1767 | 344 | auto ctrl = scope()->preview(r[0], ActionMetadata("unused", "unused"), plistener); | 347 | auto ctrl = scope()->preview(r[0], ActionMetadata("unused", "unused"), plistener); |
1768 | @@ -361,7 +364,7 @@ | |||
1769 | 361 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 364 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1770 | 362 | EXPECT_EQ("", receiver->completion_msg()); | 365 | EXPECT_EQ("", receiver->completion_msg()); |
1771 | 363 | auto r = receiver->results(); | 366 | auto r = receiver->results(); |
1773 | 364 | EXPECT_EQ(1, r.size()); | 367 | EXPECT_EQ(1u, r.size()); |
1774 | 365 | 368 | ||
1775 | 366 | auto alistener = make_shared<ActivationListener>(); | 369 | auto alistener = make_shared<ActivationListener>(); |
1776 | 367 | scope()->activate(r[0], ActionMetadata("unused", "unused"), alistener); | 370 | scope()->activate(r[0], ActionMetadata("unused", "unused"), alistener); |
1777 | @@ -383,7 +386,7 @@ | |||
1778 | 383 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 386 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1779 | 384 | EXPECT_EQ("", receiver->completion_msg()); | 387 | EXPECT_EQ("", receiver->completion_msg()); |
1780 | 385 | auto r = receiver->results(); | 388 | auto r = receiver->results(); |
1782 | 386 | EXPECT_EQ(1, r.size()); | 389 | EXPECT_EQ(1u, r.size()); |
1783 | 387 | 390 | ||
1784 | 388 | auto alistener = make_shared<ActivationListener>(); | 391 | auto alistener = make_shared<ActivationListener>(); |
1785 | 389 | scope()->activate(r[0], ActionMetadata("unused", "unused"), alistener); | 392 | scope()->activate(r[0], ActionMetadata("unused", "unused"), alistener); |
1786 | @@ -403,7 +406,7 @@ | |||
1787 | 403 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 406 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1788 | 404 | EXPECT_EQ("", receiver->completion_msg()); | 407 | EXPECT_EQ("", receiver->completion_msg()); |
1789 | 405 | auto r = receiver->results(); | 408 | auto r = receiver->results(); |
1791 | 406 | EXPECT_EQ(1, r.size()); | 409 | EXPECT_EQ(1u, r.size()); |
1792 | 407 | 410 | ||
1793 | 408 | auto alistener = make_shared<ActivationListener>(); | 411 | auto alistener = make_shared<ActivationListener>(); |
1794 | 409 | auto ctrl = scope()->activate(r[0], ActionMetadata("unused", "unused"), alistener); | 412 | auto ctrl = scope()->activate(r[0], ActionMetadata("unused", "unused"), alistener); |
1795 | @@ -426,7 +429,7 @@ | |||
1796 | 426 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); | 429 | EXPECT_EQ(CompletionDetails::CompletionStatus::OK, receiver->completion_status()); |
1797 | 427 | EXPECT_EQ("", receiver->completion_msg()); | 430 | EXPECT_EQ("", receiver->completion_msg()); |
1798 | 428 | auto r = receiver->results(); | 431 | auto r = receiver->results(); |
1800 | 429 | EXPECT_EQ(1, r.size()); | 432 | EXPECT_EQ(1u, r.size()); |
1801 | 430 | 433 | ||
1802 | 431 | auto alistener = make_shared<ActivationListener>(); | 434 | auto alistener = make_shared<ActivationListener>(); |
1803 | 432 | scope()->perform_action(r[0], ActionMetadata("unused", "unused"), "", "", alistener); | 435 | scope()->perform_action(r[0], ActionMetadata("unused", "unused"), "", "", alistener); |
1804 | 433 | 436 | ||
1805 | === modified file 'test/gtest/scopes/ValueSliderFilter/ValueSliderFilter_test.cpp' | |||
1806 | --- test/gtest/scopes/ValueSliderFilter/ValueSliderFilter_test.cpp 2016-03-11 13:21:36 +0000 | |||
1807 | +++ test/gtest/scopes/ValueSliderFilter/ValueSliderFilter_test.cpp 2017-01-16 06:43:13 +0000 | |||
1808 | @@ -16,7 +16,11 @@ | |||
1809 | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> |
1810 | 17 | */ | 17 | */ |
1811 | 18 | 18 | ||
1812 | 19 | #pragma GCC diagnostic push | ||
1813 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1814 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
1815 | 22 | #pragma GCC diagnostic pop | ||
1816 | 23 | |||
1817 | 20 | #include <unity/scopes/FilterState.h> | 24 | #include <unity/scopes/FilterState.h> |
1818 | 21 | #include <unity/scopes/ValueSliderFilter.h> | 25 | #include <unity/scopes/ValueSliderFilter.h> |
1819 | 22 | #include <unity/scopes/ValueSliderLabels.h> | 26 | #include <unity/scopes/ValueSliderLabels.h> |
1820 | @@ -45,7 +49,7 @@ | |||
1821 | 45 | EXPECT_EQ("f1", filter1->id()); | 49 | EXPECT_EQ("f1", filter1->id()); |
1822 | 46 | EXPECT_EQ("Min", filter1->labels().min_label()); | 50 | EXPECT_EQ("Min", filter1->labels().min_label()); |
1823 | 47 | EXPECT_EQ("Max", filter1->labels().max_label()); | 51 | EXPECT_EQ("Max", filter1->labels().max_label()); |
1825 | 48 | EXPECT_EQ(2, filter1->labels().extra_labels().size()); | 52 | EXPECT_EQ(2u, filter1->labels().extra_labels().size()); |
1826 | 49 | EXPECT_EQ("Ten", filter1->labels().extra_labels()[0].second); | 53 | EXPECT_EQ("Ten", filter1->labels().extra_labels()[0].second); |
1827 | 50 | EXPECT_EQ("Fifty", filter1->labels().extra_labels()[1].second); | 54 | EXPECT_EQ("Fifty", filter1->labels().extra_labels()[1].second); |
1828 | 51 | EXPECT_EQ(50, filter1->default_value()); | 55 | EXPECT_EQ(50, filter1->default_value()); |
1829 | @@ -115,7 +119,7 @@ | |||
1830 | 115 | EXPECT_EQ("f1", filter2->id()); | 119 | EXPECT_EQ("f1", filter2->id()); |
1831 | 116 | EXPECT_EQ("Min", filter2->labels().min_label()); | 120 | EXPECT_EQ("Min", filter2->labels().min_label()); |
1832 | 117 | EXPECT_EQ("Max", filter2->labels().max_label()); | 121 | EXPECT_EQ("Max", filter2->labels().max_label()); |
1834 | 118 | EXPECT_EQ(1, filter2->labels().extra_labels().size()); | 122 | EXPECT_EQ(1u, filter2->labels().extra_labels().size()); |
1835 | 119 | EXPECT_EQ(10, filter2->labels().extra_labels()[0].first); | 123 | EXPECT_EQ(10, filter2->labels().extra_labels()[0].first); |
1836 | 120 | EXPECT_EQ("Ten", filter2->labels().extra_labels()[0].second); | 124 | EXPECT_EQ("Ten", filter2->labels().extra_labels()[0].second); |
1837 | 121 | EXPECT_EQ(1, filter2->min()); | 125 | EXPECT_EQ(1, filter2->min()); |
1838 | 122 | 126 | ||
1839 | === modified file 'test/gtest/scopes/Variant/Variant_test.cpp' | |||
1840 | --- test/gtest/scopes/Variant/Variant_test.cpp 2015-06-17 10:15:34 +0000 | |||
1841 | +++ test/gtest/scopes/Variant/Variant_test.cpp 2017-01-16 06:43:13 +0000 | |||
1842 | @@ -21,7 +21,10 @@ | |||
1843 | 21 | 21 | ||
1844 | 22 | #include <boost/variant.hpp> | 22 | #include <boost/variant.hpp> |
1845 | 23 | 23 | ||
1846 | 24 | #pragma GCC diagnostic push | ||
1847 | 25 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1848 | 24 | #include <gtest/gtest.h> | 26 | #include <gtest/gtest.h> |
1849 | 27 | #pragma GCC diagnostic pop | ||
1850 | 25 | 28 | ||
1851 | 26 | using namespace std; | 29 | using namespace std; |
1852 | 27 | using namespace unity; | 30 | using namespace unity; |
1853 | @@ -292,12 +295,12 @@ | |||
1854 | 292 | 295 | ||
1855 | 293 | v = Variant::deserialize_json("{\"foo\": \"bar\"}"); | 296 | v = Variant::deserialize_json("{\"foo\": \"bar\"}"); |
1856 | 294 | VariantMap vm = v.get_dict(); | 297 | VariantMap vm = v.get_dict(); |
1858 | 295 | EXPECT_EQ(1, vm.size()); | 298 | EXPECT_EQ(1u, vm.size()); |
1859 | 296 | EXPECT_EQ("bar", vm.at("foo").get_string()); | 299 | EXPECT_EQ("bar", vm.at("foo").get_string()); |
1860 | 297 | 300 | ||
1861 | 298 | v = Variant::deserialize_json("[1, \"two\"]"); | 301 | v = Variant::deserialize_json("[1, \"two\"]"); |
1862 | 299 | VariantArray va = v.get_array(); | 302 | VariantArray va = v.get_array(); |
1864 | 300 | EXPECT_EQ(2, va.size()); | 303 | EXPECT_EQ(2u, va.size()); |
1865 | 301 | EXPECT_EQ(1, va[0].get_int()); | 304 | EXPECT_EQ(1, va[0].get_int()); |
1866 | 302 | EXPECT_EQ("two", va[1].get_string()); | 305 | EXPECT_EQ("two", va[1].get_string()); |
1867 | 303 | } | 306 | } |
1868 | 304 | 307 | ||
1869 | === modified file 'test/gtest/scopes/VariantBuilder/VariantBuilder_test.cpp' | |||
1870 | --- test/gtest/scopes/VariantBuilder/VariantBuilder_test.cpp 2014-02-25 12:08:41 +0000 | |||
1871 | +++ test/gtest/scopes/VariantBuilder/VariantBuilder_test.cpp 2017-01-16 06:43:13 +0000 | |||
1872 | @@ -17,8 +17,12 @@ | |||
1873 | 17 | */ | 17 | */ |
1874 | 18 | 18 | ||
1875 | 19 | #include <unity/scopes/VariantBuilder.h> | 19 | #include <unity/scopes/VariantBuilder.h> |
1876 | 20 | #include <unity/UnityExceptions.h> | ||
1877 | 21 | |||
1878 | 22 | #pragma GCC diagnostic push | ||
1879 | 23 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1880 | 20 | #include <gtest/gtest.h> | 24 | #include <gtest/gtest.h> |
1882 | 21 | #include <unity/UnityExceptions.h> | 25 | #pragma GCC diagnostic pop |
1883 | 22 | 26 | ||
1884 | 23 | using namespace unity; | 27 | using namespace unity; |
1885 | 24 | using namespace unity::scopes; | 28 | using namespace unity::scopes; |
1886 | 25 | 29 | ||
1887 | === modified file 'test/gtest/scopes/Version/Version_test.cpp' | |||
1888 | --- test/gtest/scopes/Version/Version_test.cpp 2014-01-07 12:22:29 +0000 | |||
1889 | +++ test/gtest/scopes/Version/Version_test.cpp 2017-01-16 06:43:13 +0000 | |||
1890 | @@ -18,7 +18,10 @@ | |||
1891 | 18 | 18 | ||
1892 | 19 | #include <unity/scopes/Version.h> | 19 | #include <unity/scopes/Version.h> |
1893 | 20 | 20 | ||
1894 | 21 | #pragma GCC diagnostic push | ||
1895 | 22 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1896 | 21 | #include <gtest/gtest.h> | 23 | #include <gtest/gtest.h> |
1897 | 24 | #pragma GCC diagnostic pop | ||
1898 | 22 | 25 | ||
1899 | 23 | using namespace unity::scopes; | 26 | using namespace unity::scopes; |
1900 | 24 | 27 | ||
1901 | 25 | 28 | ||
1902 | === modified file 'test/gtest/scopes/internal/CategoryRegistry/CategoryRegistry_test.cpp' | |||
1903 | --- test/gtest/scopes/internal/CategoryRegistry/CategoryRegistry_test.cpp 2014-07-02 09:36:34 +0000 | |||
1904 | +++ test/gtest/scopes/internal/CategoryRegistry/CategoryRegistry_test.cpp 2017-01-16 06:43:13 +0000 | |||
1905 | @@ -21,7 +21,10 @@ | |||
1906 | 21 | #include <unity/UnityExceptions.h> | 21 | #include <unity/UnityExceptions.h> |
1907 | 22 | #include <unity/scopes/Variant.h> | 22 | #include <unity/scopes/Variant.h> |
1908 | 23 | 23 | ||
1909 | 24 | #pragma GCC diagnostic push | ||
1910 | 25 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1911 | 24 | #include <gtest/gtest.h> | 26 | #include <gtest/gtest.h> |
1912 | 27 | #pragma GCC diagnostic pop | ||
1913 | 25 | 28 | ||
1914 | 26 | using namespace std; | 29 | using namespace std; |
1915 | 27 | using namespace unity; | 30 | using namespace unity; |
1916 | 28 | 31 | ||
1917 | === modified file 'test/gtest/scopes/internal/ConfigBase/ConfigBase_test.cpp' | |||
1918 | --- test/gtest/scopes/internal/ConfigBase/ConfigBase_test.cpp 2014-07-07 23:53:36 +0000 | |||
1919 | +++ test/gtest/scopes/internal/ConfigBase/ConfigBase_test.cpp 2017-01-16 06:43:13 +0000 | |||
1920 | @@ -20,7 +20,10 @@ | |||
1921 | 20 | #include <unity/scopes/ScopeExceptions.h> | 20 | #include <unity/scopes/ScopeExceptions.h> |
1922 | 21 | #include <unity/UnityExceptions.h> | 21 | #include <unity/UnityExceptions.h> |
1923 | 22 | 22 | ||
1924 | 23 | #pragma GCC diagnostic push | ||
1925 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1926 | 23 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
1927 | 26 | #pragma GCC diagnostic pop | ||
1928 | 24 | 27 | ||
1929 | 25 | using namespace std; | 28 | using namespace std; |
1930 | 26 | using namespace unity; | 29 | using namespace unity; |
1931 | 27 | 30 | ||
1932 | === modified file 'test/gtest/scopes/internal/DynamicLoader/DynamicLoader_test.cpp' | |||
1933 | --- test/gtest/scopes/internal/DynamicLoader/DynamicLoader_test.cpp 2014-08-28 00:20:56 +0000 | |||
1934 | +++ test/gtest/scopes/internal/DynamicLoader/DynamicLoader_test.cpp 2017-01-16 06:43:13 +0000 | |||
1935 | @@ -19,7 +19,10 @@ | |||
1936 | 19 | #include <unity/scopes/internal/DynamicLoader.h> | 19 | #include <unity/scopes/internal/DynamicLoader.h> |
1937 | 20 | #include <unity/UnityExceptions.h> | 20 | #include <unity/UnityExceptions.h> |
1938 | 21 | 21 | ||
1939 | 22 | #pragma GCC diagnostic push | ||
1940 | 23 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1941 | 22 | #include <gtest/gtest.h> | 24 | #include <gtest/gtest.h> |
1942 | 25 | #pragma GCC diagnostic pop | ||
1943 | 23 | 26 | ||
1944 | 24 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. | 27 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. |
1945 | 25 | using namespace std; | 28 | using namespace std; |
1946 | 26 | 29 | ||
1947 | === modified file 'test/gtest/scopes/internal/IniSettingsSchema/IniSettingsSchema_test.cpp' | |||
1948 | --- test/gtest/scopes/internal/IniSettingsSchema/IniSettingsSchema_test.cpp 2014-11-20 21:33:33 +0000 | |||
1949 | +++ test/gtest/scopes/internal/IniSettingsSchema/IniSettingsSchema_test.cpp 2017-01-16 06:43:13 +0000 | |||
1950 | @@ -21,7 +21,10 @@ | |||
1951 | 21 | #include <unity/UnityExceptions.h> | 21 | #include <unity/UnityExceptions.h> |
1952 | 22 | 22 | ||
1953 | 23 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. | 23 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. |
1954 | 24 | #pragma GCC diagnostic push | ||
1955 | 25 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
1956 | 24 | #include <gtest/gtest.h> | 26 | #include <gtest/gtest.h> |
1957 | 27 | #pragma GCC diagnostic pop | ||
1958 | 25 | 28 | ||
1959 | 26 | using namespace unity; | 29 | using namespace unity; |
1960 | 27 | using namespace unity::scopes; | 30 | using namespace unity::scopes; |
1961 | @@ -34,7 +37,7 @@ | |||
1962 | 34 | s->add_location_setting(); | 37 | s->add_location_setting(); |
1963 | 35 | 38 | ||
1964 | 36 | auto defs = s->definitions(); | 39 | auto defs = s->definitions(); |
1966 | 37 | ASSERT_EQ(9, defs.size()); | 40 | ASSERT_EQ(9u, defs.size()); |
1967 | 38 | 41 | ||
1968 | 39 | EXPECT_EQ("location", defs[0].get_dict()["id"].get_string()); | 42 | EXPECT_EQ("location", defs[0].get_dict()["id"].get_string()); |
1969 | 40 | EXPECT_EQ("string", defs[0].get_dict()["type"].get_string()); | 43 | EXPECT_EQ("string", defs[0].get_dict()["type"].get_string()); |
1970 | @@ -45,7 +48,7 @@ | |||
1971 | 45 | EXPECT_EQ("list", defs[1].get_dict()["type"].get_string()); | 48 | EXPECT_EQ("list", defs[1].get_dict()["type"].get_string()); |
1972 | 46 | EXPECT_EQ("Temperature Unit", defs[1].get_dict()["displayName"].get_string()); | 49 | EXPECT_EQ("Temperature Unit", defs[1].get_dict()["displayName"].get_string()); |
1973 | 47 | EXPECT_EQ(1, defs[1].get_dict()["defaultValue"].get_int()); | 50 | EXPECT_EQ(1, defs[1].get_dict()["defaultValue"].get_int()); |
1975 | 48 | ASSERT_EQ(2, defs[1].get_dict()["displayValues"].get_array().size()); | 51 | ASSERT_EQ(2u, defs[1].get_dict()["displayValues"].get_array().size()); |
1976 | 49 | EXPECT_EQ("Celsius", defs[1].get_dict()["displayValues"].get_array()[0].get_string()); | 52 | EXPECT_EQ("Celsius", defs[1].get_dict()["displayValues"].get_array()[0].get_string()); |
1977 | 50 | EXPECT_EQ("Fahrenheit", defs[1].get_dict()["displayValues"].get_array()[1].get_string()); | 53 | EXPECT_EQ("Fahrenheit", defs[1].get_dict()["displayValues"].get_array()[1].get_string()); |
1978 | 51 | 54 | ||
1979 | @@ -204,7 +207,7 @@ | |||
1980 | 204 | 207 | ||
1981 | 205 | EXPECT_EQ("tempUnit", defs[1].get_dict()["id"].get_string()); | 208 | EXPECT_EQ("tempUnit", defs[1].get_dict()["id"].get_string()); |
1982 | 206 | EXPECT_EQ("testTemperature Unit", defs[1].get_dict()["displayName"].get_string()); | 209 | EXPECT_EQ("testTemperature Unit", defs[1].get_dict()["displayName"].get_string()); |
1984 | 207 | ASSERT_EQ(2, defs[1].get_dict()["displayValues"].get_array().size()); | 210 | ASSERT_EQ(2u, defs[1].get_dict()["displayValues"].get_array().size()); |
1985 | 208 | EXPECT_EQ("testCelsius", defs[1].get_dict()["displayValues"].get_array()[0].get_string()); | 211 | EXPECT_EQ("testCelsius", defs[1].get_dict()["displayValues"].get_array()[0].get_string()); |
1986 | 209 | EXPECT_EQ("testFahrenheit", defs[1].get_dict()["displayValues"].get_array()[1].get_string()); | 212 | EXPECT_EQ("testFahrenheit", defs[1].get_dict()["displayValues"].get_array()[1].get_string()); |
1987 | 210 | } | 213 | } |
1988 | @@ -215,11 +218,11 @@ | |||
1989 | 215 | auto s = IniSettingsSchema::create(TEST_SRC_DIR "/locale_fallback.ini"); | 218 | auto s = IniSettingsSchema::create(TEST_SRC_DIR "/locale_fallback.ini"); |
1990 | 216 | 219 | ||
1991 | 217 | auto defs = s->definitions(); | 220 | auto defs = s->definitions(); |
1993 | 218 | ASSERT_EQ(1, defs.size()); | 221 | ASSERT_EQ(1u, defs.size()); |
1994 | 219 | 222 | ||
1995 | 220 | EXPECT_EQ("tempUnit", defs[0].get_dict()["id"].get_string()); | 223 | EXPECT_EQ("tempUnit", defs[0].get_dict()["id"].get_string()); |
1996 | 221 | EXPECT_EQ("Temperature Unit", defs[0].get_dict()["displayName"].get_string()); | 224 | EXPECT_EQ("Temperature Unit", defs[0].get_dict()["displayName"].get_string()); |
1998 | 222 | ASSERT_EQ(2, defs[0].get_dict()["displayValues"].get_array().size()); | 225 | ASSERT_EQ(2u, defs[0].get_dict()["displayValues"].get_array().size()); |
1999 | 223 | EXPECT_EQ("Celsius", defs[0].get_dict()["displayValues"].get_array()[0].get_string()); | 226 | EXPECT_EQ("Celsius", defs[0].get_dict()["displayValues"].get_array()[0].get_string()); |
2000 | 224 | EXPECT_EQ("Fahrenheit", defs[0].get_dict()["displayValues"].get_array()[1].get_string()); | 227 | EXPECT_EQ("Fahrenheit", defs[0].get_dict()["displayValues"].get_array()[1].get_string()); |
2001 | 225 | } | 228 | } |
2002 | @@ -235,7 +238,7 @@ | |||
2003 | 235 | s->add_location_setting(); | 238 | s->add_location_setting(); |
2004 | 236 | { | 239 | { |
2005 | 237 | auto defs = s->definitions(); | 240 | auto defs = s->definitions(); |
2007 | 238 | ASSERT_EQ(1, defs.size()); | 241 | ASSERT_EQ(1u, defs.size()); |
2008 | 239 | 242 | ||
2009 | 240 | EXPECT_EQ("internal.location", defs[0].get_dict()["id"].get_string()); | 243 | EXPECT_EQ("internal.location", defs[0].get_dict()["id"].get_string()); |
2010 | 241 | EXPECT_EQ("Enable location data", defs[0].get_dict()["displayName"].get_string()); | 244 | EXPECT_EQ("Enable location data", defs[0].get_dict()["displayName"].get_string()); |
2011 | 242 | 245 | ||
2012 | === modified file 'test/gtest/scopes/internal/JsonNode/JsonNode_test.cpp' | |||
2013 | --- test/gtest/scopes/internal/JsonNode/JsonNode_test.cpp 2016-05-27 11:26:53 +0000 | |||
2014 | +++ test/gtest/scopes/internal/JsonNode/JsonNode_test.cpp 2017-01-16 06:43:13 +0000 | |||
2015 | @@ -20,7 +20,11 @@ | |||
2016 | 20 | #include <unity/UnityExceptions.h> | 20 | #include <unity/UnityExceptions.h> |
2017 | 21 | #include <unity/scopes/Variant.h> | 21 | #include <unity/scopes/Variant.h> |
2018 | 22 | 22 | ||
2019 | 23 | #pragma GCC diagnostic push | ||
2020 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2021 | 23 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
2022 | 26 | #pragma GCC diagnostic pop | ||
2023 | 27 | |||
2024 | 24 | #include <memory> | 28 | #include <memory> |
2025 | 25 | #include <algorithm> | 29 | #include <algorithm> |
2026 | 26 | 30 | ||
2027 | 27 | 31 | ||
2028 | === modified file 'test/gtest/scopes/internal/JsonSettingsSchema/JsonSettingsSchema_test.cpp' | |||
2029 | --- test/gtest/scopes/internal/JsonSettingsSchema/JsonSettingsSchema_test.cpp 2016-05-27 11:03:57 +0000 | |||
2030 | +++ test/gtest/scopes/internal/JsonSettingsSchema/JsonSettingsSchema_test.cpp 2017-01-16 06:43:13 +0000 | |||
2031 | @@ -21,7 +21,10 @@ | |||
2032 | 21 | #include <unity/UnityExceptions.h> | 21 | #include <unity/UnityExceptions.h> |
2033 | 22 | #include <unity/util/FileIO.h> | 22 | #include <unity/util/FileIO.h> |
2034 | 23 | 23 | ||
2035 | 24 | #pragma GCC diagnostic push | ||
2036 | 25 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2037 | 24 | #include <gtest/gtest.h> | 26 | #include <gtest/gtest.h> |
2038 | 27 | #pragma GCC diagnostic pop | ||
2039 | 25 | 28 | ||
2040 | 26 | using namespace unity; | 29 | using namespace unity; |
2041 | 27 | using namespace unity::scopes; | 30 | using namespace unity::scopes; |
2042 | @@ -118,7 +121,7 @@ | |||
2043 | 118 | auto s = JsonSettingsSchema::create(ok_schema); | 121 | auto s = JsonSettingsSchema::create(ok_schema); |
2044 | 119 | 122 | ||
2045 | 120 | auto defs = s->definitions(); | 123 | auto defs = s->definitions(); |
2047 | 121 | EXPECT_EQ(11, defs.size()); | 124 | EXPECT_EQ(11u, defs.size()); |
2048 | 122 | 125 | ||
2049 | 123 | EXPECT_EQ("location", defs[0].get_dict()["id"].get_string()); | 126 | EXPECT_EQ("location", defs[0].get_dict()["id"].get_string()); |
2050 | 124 | EXPECT_EQ("string", defs[0].get_dict()["type"].get_string()); | 127 | EXPECT_EQ("string", defs[0].get_dict()["type"].get_string()); |
2051 | @@ -129,7 +132,7 @@ | |||
2052 | 129 | EXPECT_EQ("list", defs[1].get_dict()["type"].get_string()); | 132 | EXPECT_EQ("list", defs[1].get_dict()["type"].get_string()); |
2053 | 130 | EXPECT_EQ("Temperature Units", defs[1].get_dict()["displayName"].get_string()); | 133 | EXPECT_EQ("Temperature Units", defs[1].get_dict()["displayName"].get_string()); |
2054 | 131 | EXPECT_EQ(1, defs[1].get_dict()["defaultValue"].get_int()); | 134 | EXPECT_EQ(1, defs[1].get_dict()["defaultValue"].get_int()); |
2056 | 132 | EXPECT_EQ(2, defs[1].get_dict()["displayValues"].get_array().size()); | 135 | EXPECT_EQ(2u, defs[1].get_dict()["displayValues"].get_array().size()); |
2057 | 133 | EXPECT_EQ("Celsius", defs[1].get_dict()["displayValues"].get_array()[0].get_string()); | 136 | EXPECT_EQ("Celsius", defs[1].get_dict()["displayValues"].get_array()[0].get_string()); |
2058 | 134 | EXPECT_EQ("Fahrenheit", defs[1].get_dict()["displayValues"].get_array()[1].get_string()); | 137 | EXPECT_EQ("Fahrenheit", defs[1].get_dict()["displayValues"].get_array()[1].get_string()); |
2059 | 135 | 138 | ||
2060 | @@ -181,7 +184,7 @@ | |||
2061 | 181 | auto s = JsonSettingsSchema::create(schema); | 184 | auto s = JsonSettingsSchema::create(schema); |
2062 | 182 | 185 | ||
2063 | 183 | auto defs = s->definitions(); | 186 | auto defs = s->definitions(); |
2065 | 184 | EXPECT_EQ(2, defs.size()); | 187 | EXPECT_EQ(2u, defs.size()); |
2066 | 185 | 188 | ||
2067 | 186 | EXPECT_EQ(3.14, defs[0].get_dict()["defaultValue"].get_double()); | 189 | EXPECT_EQ(3.14, defs[0].get_dict()["defaultValue"].get_double()); |
2068 | 187 | EXPECT_EQ(2147483648, defs[1].get_dict()["defaultValue"].get_double()); | 190 | EXPECT_EQ(2147483648, defs[1].get_dict()["defaultValue"].get_double()); |
2069 | @@ -705,7 +708,7 @@ | |||
2070 | 705 | s->add_location_setting(); | 708 | s->add_location_setting(); |
2071 | 706 | { | 709 | { |
2072 | 707 | auto defs = s->definitions(); | 710 | auto defs = s->definitions(); |
2074 | 708 | ASSERT_EQ(1, defs.size()); | 711 | ASSERT_EQ(1u, defs.size()); |
2075 | 709 | 712 | ||
2076 | 710 | EXPECT_EQ("internal.location", defs[0].get_dict()["id"].get_string()); | 713 | EXPECT_EQ("internal.location", defs[0].get_dict()["id"].get_string()); |
2077 | 711 | EXPECT_EQ("Enable location data", defs[0].get_dict()["displayName"].get_string()); | 714 | EXPECT_EQ("Enable location data", defs[0].get_dict()["displayName"].get_string()); |
2078 | 712 | 715 | ||
2079 | === modified file 'test/gtest/scopes/internal/Logger/Logger_test.cpp' | |||
2080 | --- test/gtest/scopes/internal/Logger/Logger_test.cpp 2016-02-22 04:35:26 +0000 | |||
2081 | +++ test/gtest/scopes/internal/Logger/Logger_test.cpp 2017-01-16 06:43:13 +0000 | |||
2082 | @@ -19,7 +19,12 @@ | |||
2083 | 19 | #include <unity/scopes/internal/Logger.h> | 19 | #include <unity/scopes/internal/Logger.h> |
2084 | 20 | 20 | ||
2085 | 21 | #include <boost/algorithm/string.hpp> | 21 | #include <boost/algorithm/string.hpp> |
2086 | 22 | |||
2087 | 23 | #pragma GCC diagnostic push | ||
2088 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2089 | 22 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
2090 | 26 | #pragma GCC diagnostic pop | ||
2091 | 27 | |||
2092 | 23 | #include <unity/UnityExceptions.h> | 28 | #include <unity/UnityExceptions.h> |
2093 | 24 | 29 | ||
2094 | 25 | using namespace std; | 30 | using namespace std; |
2095 | 26 | 31 | ||
2096 | === modified file 'test/gtest/scopes/internal/MiddlewareFactory/MiddlewareFactory_test.cpp' | |||
2097 | --- test/gtest/scopes/internal/MiddlewareFactory/MiddlewareFactory_test.cpp 2014-12-02 00:16:04 +0000 | |||
2098 | +++ test/gtest/scopes/internal/MiddlewareFactory/MiddlewareFactory_test.cpp 2017-01-16 06:43:13 +0000 | |||
2099 | @@ -19,7 +19,10 @@ | |||
2100 | 19 | #include <unity/scopes/internal/MiddlewareFactory.h> | 19 | #include <unity/scopes/internal/MiddlewareFactory.h> |
2101 | 20 | #include <unity/scopes/ScopeExceptions.h> | 20 | #include <unity/scopes/ScopeExceptions.h> |
2102 | 21 | 21 | ||
2103 | 22 | #pragma GCC diagnostic push | ||
2104 | 23 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2105 | 22 | #include <gtest/gtest.h> | 24 | #include <gtest/gtest.h> |
2106 | 25 | #pragma GCC diagnostic pop | ||
2107 | 23 | 26 | ||
2108 | 24 | using namespace std; | 27 | using namespace std; |
2109 | 25 | using namespace unity::scopes; | 28 | using namespace unity::scopes; |
2110 | 26 | 29 | ||
2111 | === modified file 'test/gtest/scopes/internal/Reaper/Reaper_test.cpp' | |||
2112 | --- test/gtest/scopes/internal/Reaper/Reaper_test.cpp 2014-11-05 05:00:38 +0000 | |||
2113 | +++ test/gtest/scopes/internal/Reaper/Reaper_test.cpp 2017-01-16 06:43:13 +0000 | |||
2114 | @@ -20,7 +20,10 @@ | |||
2115 | 20 | 20 | ||
2116 | 21 | #include <unity/UnityExceptions.h> | 21 | #include <unity/UnityExceptions.h> |
2117 | 22 | 22 | ||
2118 | 23 | #pragma GCC diagnostic push | ||
2119 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2120 | 23 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
2121 | 26 | #pragma GCC diagnostic pop | ||
2122 | 24 | 27 | ||
2123 | 25 | using namespace std; | 28 | using namespace std; |
2124 | 26 | using namespace unity::scopes; | 29 | using namespace unity::scopes; |
2125 | @@ -200,17 +203,17 @@ | |||
2126 | 200 | auto e1 = r->add([]{}); | 203 | auto e1 = r->add([]{}); |
2127 | 201 | auto e2 = r->add([]{}); | 204 | auto e2 = r->add([]{}); |
2128 | 202 | auto e3 = r->add([]{}); | 205 | auto e3 = r->add([]{}); |
2130 | 203 | EXPECT_EQ(3, r->size()); | 206 | EXPECT_EQ(3u, r->size()); |
2131 | 204 | e2->cancel(); | 207 | e2->cancel(); |
2133 | 205 | EXPECT_EQ(2, r->size()); | 208 | EXPECT_EQ(2u, r->size()); |
2134 | 206 | 209 | ||
2135 | 207 | r->destroy(); | 210 | r->destroy(); |
2136 | 208 | 211 | ||
2138 | 209 | EXPECT_EQ(2, r->size()); | 212 | EXPECT_EQ(2u, r->size()); |
2139 | 210 | e3->cancel(); | 213 | e3->cancel(); |
2141 | 211 | EXPECT_EQ(1, r->size()); | 214 | EXPECT_EQ(1u, r->size()); |
2142 | 212 | e1->cancel(); | 215 | e1->cancel(); |
2144 | 213 | EXPECT_EQ(0, r->size()); | 216 | EXPECT_EQ(0u, r->size()); |
2145 | 214 | } | 217 | } |
2146 | 215 | } | 218 | } |
2147 | 216 | 219 | ||
2148 | @@ -326,7 +329,7 @@ | |||
2149 | 326 | // Now we destroy the reaper, *before* the pass at t == 6.0. | 329 | // Now we destroy the reaper, *before* the pass at t == 6.0. |
2150 | 327 | // Because CallbackOnDestroy is set, e3 is reaped. | 330 | // Because CallbackOnDestroy is set, e3 is reaped. |
2151 | 328 | r->destroy(); | 331 | r->destroy(); |
2153 | 329 | EXPECT_EQ(0, r->size()); | 332 | EXPECT_EQ(0u, r->size()); |
2154 | 330 | EXPECT_EQ(1, c1.get()); | 333 | EXPECT_EQ(1, c1.get()); |
2155 | 331 | EXPECT_EQ(0, c2.get()); | 334 | EXPECT_EQ(0, c2.get()); |
2156 | 332 | EXPECT_EQ(1, c3.get()); // Callback for e3 must have been invoked. | 335 | EXPECT_EQ(1, c3.get()); // Callback for e3 must have been invoked. |
2157 | @@ -361,7 +364,7 @@ | |||
2158 | 361 | 364 | ||
2159 | 362 | // e1 is oldest, so at the tail of the reap list. | 365 | // e1 is oldest, so at the tail of the reap list. |
2160 | 363 | 366 | ||
2162 | 364 | EXPECT_EQ(2, r->size()); | 367 | EXPECT_EQ(2u, r->size()); |
2163 | 365 | EXPECT_LT(t(), 2000); | 368 | EXPECT_LT(t(), 2000); |
2164 | 366 | 369 | ||
2165 | 367 | this_thread::sleep_for(chrono::milliseconds(2500)); // At t == 2.0, reaper kicks in. | 370 | this_thread::sleep_for(chrono::milliseconds(2500)); // At t == 2.0, reaper kicks in. |
2166 | @@ -370,14 +373,14 @@ | |||
2167 | 370 | EXPECT_GE(t(), 2500); | 373 | EXPECT_GE(t(), 2500); |
2168 | 371 | EXPECT_EQ(1, c1.get()); // Was reaped at t ~ 2.0 (tested by lambda on c1) | 374 | EXPECT_EQ(1, c1.get()); // Was reaped at t ~ 2.0 (tested by lambda on c1) |
2169 | 372 | EXPECT_EQ(0, c2.get()); // Expires at t ~ 2.0, but not reaped yet, because c1 has not completed | 375 | EXPECT_EQ(0, c2.get()); // Expires at t ~ 2.0, but not reaped yet, because c1 has not completed |
2171 | 373 | EXPECT_EQ(1, r->size()); // e2 must still be there | 376 | EXPECT_EQ(1u, r->size()); // e2 must still be there |
2172 | 374 | 377 | ||
2173 | 375 | // We null out e2 while the reaping pass is still stuck in the callback for e1. | 378 | // We null out e2 while the reaping pass is still stuck in the callback for e1. |
2174 | 376 | EXPECT_LT(t(), 3000); | 379 | EXPECT_LT(t(), 3000); |
2175 | 377 | e2 = nullptr; // Blocks until e1's callback completes at t ~ 3.0 (tested by lambda on c2) | 380 | e2 = nullptr; // Blocks until e1's callback completes at t ~ 3.0 (tested by lambda on c2) |
2176 | 378 | EXPECT_GE(t(), 3000); | 381 | EXPECT_GE(t(), 3000); |
2177 | 379 | EXPECT_EQ(0, c2.get()); | 382 | EXPECT_EQ(0, c2.get()); |
2179 | 380 | EXPECT_EQ(0, r->size()); | 383 | EXPECT_EQ(0u, r->size()); |
2180 | 381 | } | 384 | } |
2181 | 382 | } | 385 | } |
2182 | 383 | 386 | ||
2183 | @@ -419,7 +422,7 @@ | |||
2184 | 419 | SelfDestroy sd(r); | 422 | SelfDestroy sd(r); |
2185 | 420 | this_thread::sleep_for(chrono::milliseconds(1500)); | 423 | this_thread::sleep_for(chrono::milliseconds(1500)); |
2186 | 421 | EXPECT_TRUE(sd.called()); | 424 | EXPECT_TRUE(sd.called()); |
2188 | 422 | EXPECT_EQ(0, r->size()); | 425 | EXPECT_EQ(0u, r->size()); |
2189 | 423 | } | 426 | } |
2190 | 424 | } | 427 | } |
2191 | 425 | 428 | ||
2192 | @@ -441,13 +444,13 @@ | |||
2193 | 441 | 444 | ||
2194 | 442 | e1->refresh(); | 445 | e1->refresh(); |
2195 | 443 | e2->cancel(); | 446 | e2->cancel(); |
2197 | 444 | EXPECT_EQ(2, r->size()); | 447 | EXPECT_EQ(2u, r->size()); |
2198 | 445 | EXPECT_EQ(0, c1.get()); | 448 | EXPECT_EQ(0, c1.get()); |
2199 | 446 | EXPECT_EQ(0, c2.get()); | 449 | EXPECT_EQ(0, c2.get()); |
2200 | 447 | EXPECT_EQ(0, c3.get()); | 450 | EXPECT_EQ(0, c3.get()); |
2201 | 448 | 451 | ||
2202 | 449 | r->destroy(); | 452 | r->destroy(); |
2204 | 450 | EXPECT_EQ(0, r->size()); | 453 | EXPECT_EQ(0u, r->size()); |
2205 | 451 | EXPECT_EQ(1, c1.get()); | 454 | EXPECT_EQ(1, c1.get()); |
2206 | 452 | EXPECT_EQ(0, c2.get()); | 455 | EXPECT_EQ(0, c2.get()); |
2207 | 453 | EXPECT_EQ(1, c3.get()); | 456 | EXPECT_EQ(1, c3.get()); |
2208 | @@ -466,13 +469,13 @@ | |||
2209 | 466 | 469 | ||
2210 | 467 | e1->refresh(); | 470 | e1->refresh(); |
2211 | 468 | e2->cancel(); | 471 | e2->cancel(); |
2213 | 469 | EXPECT_EQ(2, r->size()); | 472 | EXPECT_EQ(2u, r->size()); |
2214 | 470 | EXPECT_EQ(0, c1.get()); | 473 | EXPECT_EQ(0, c1.get()); |
2215 | 471 | EXPECT_EQ(0, c2.get()); | 474 | EXPECT_EQ(0, c2.get()); |
2216 | 472 | EXPECT_EQ(0, c3.get()); | 475 | EXPECT_EQ(0, c3.get()); |
2217 | 473 | 476 | ||
2218 | 474 | r->destroy(); | 477 | r->destroy(); |
2220 | 475 | EXPECT_EQ(2, r->size()); | 478 | EXPECT_EQ(2u, r->size()); |
2221 | 476 | EXPECT_EQ(0, c1.get()); | 479 | EXPECT_EQ(0, c1.get()); |
2222 | 477 | EXPECT_EQ(0, c2.get()); | 480 | EXPECT_EQ(0, c2.get()); |
2223 | 478 | EXPECT_EQ(0, c3.get()); | 481 | EXPECT_EQ(0, c3.get()); |
2224 | 479 | 482 | ||
2225 | === modified file 'test/gtest/scopes/internal/RegistryConfig/RegistryConfig_test.cpp' | |||
2226 | --- test/gtest/scopes/internal/RegistryConfig/RegistryConfig_test.cpp 2015-08-04 04:56:01 +0000 | |||
2227 | +++ test/gtest/scopes/internal/RegistryConfig/RegistryConfig_test.cpp 2017-01-16 06:43:13 +0000 | |||
2228 | @@ -21,7 +21,10 @@ | |||
2229 | 21 | #include <unity/scopes/ScopeExceptions.h> | 21 | #include <unity/scopes/ScopeExceptions.h> |
2230 | 22 | 22 | ||
2231 | 23 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. | 23 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. |
2232 | 24 | #pragma GCC diagnostic push | ||
2233 | 25 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2234 | 24 | #include <gtest/gtest.h> | 26 | #include <gtest/gtest.h> |
2235 | 27 | #pragma GCC diagnostic pop | ||
2236 | 25 | 28 | ||
2237 | 26 | using namespace std; | 29 | using namespace std; |
2238 | 27 | using namespace unity; | 30 | using namespace unity; |
2239 | 28 | 31 | ||
2240 | === modified file 'test/gtest/scopes/internal/RegistryObject/RegistryObject_test.cpp' | |||
2241 | --- test/gtest/scopes/internal/RegistryObject/RegistryObject_test.cpp 2015-05-29 10:17:42 +0000 | |||
2242 | +++ test/gtest/scopes/internal/RegistryObject/RegistryObject_test.cpp 2017-01-16 06:43:13 +0000 | |||
2243 | @@ -24,8 +24,10 @@ | |||
2244 | 24 | #include <unity/UnityExceptions.h> | 24 | #include <unity/UnityExceptions.h> |
2245 | 25 | #include <unity/scopes/ScopeExceptions.h> | 25 | #include <unity/scopes/ScopeExceptions.h> |
2246 | 26 | 26 | ||
2248 | 27 | #include <gtest/gtest.h> | 27 | #pragma GCC diagnostic push |
2249 | 28 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2250 | 28 | #include <gmock/gmock.h> | 29 | #include <gmock/gmock.h> |
2251 | 30 | #pragma GCC diagnostic pop | ||
2252 | 29 | 31 | ||
2253 | 30 | using namespace std; | 32 | using namespace std; |
2254 | 31 | using namespace testing; | 33 | using namespace testing; |
2255 | 32 | 34 | ||
2256 | === modified file 'test/gtest/scopes/internal/ResultReplyObject/ResultReplyObject_test.cpp' | |||
2257 | --- test/gtest/scopes/internal/ResultReplyObject/ResultReplyObject_test.cpp 2014-12-01 08:21:05 +0000 | |||
2258 | +++ test/gtest/scopes/internal/ResultReplyObject/ResultReplyObject_test.cpp 2017-01-16 06:43:13 +0000 | |||
2259 | @@ -23,7 +23,11 @@ | |||
2260 | 23 | #include <unity/scopes/SearchListenerBase.h> | 23 | #include <unity/scopes/SearchListenerBase.h> |
2261 | 24 | #include <unity/scopes/Department.h> | 24 | #include <unity/scopes/Department.h> |
2262 | 25 | #include <unity/scopes/CategorisedResult.h> | 25 | #include <unity/scopes/CategorisedResult.h> |
2263 | 26 | |||
2264 | 27 | #pragma GCC diagnostic push | ||
2265 | 28 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2266 | 26 | #include <gtest/gtest.h> | 29 | #include <gtest/gtest.h> |
2267 | 30 | #pragma GCC diagnostic pop | ||
2268 | 27 | 31 | ||
2269 | 28 | using namespace unity::scopes; | 32 | using namespace unity::scopes; |
2270 | 29 | using namespace unity::scopes::internal; | 33 | using namespace unity::scopes::internal; |
2271 | 30 | 34 | ||
2272 | === modified file 'test/gtest/scopes/internal/RuntimeConfig/RuntimeConfig_test.cpp' | |||
2273 | --- test/gtest/scopes/internal/RuntimeConfig/RuntimeConfig_test.cpp 2016-02-22 01:29:01 +0000 | |||
2274 | +++ test/gtest/scopes/internal/RuntimeConfig/RuntimeConfig_test.cpp 2017-01-16 06:43:13 +0000 | |||
2275 | @@ -24,7 +24,10 @@ | |||
2276 | 24 | #include <unity/UnityExceptions.h> | 24 | #include <unity/UnityExceptions.h> |
2277 | 25 | 25 | ||
2278 | 26 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. | 26 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. |
2279 | 27 | #pragma GCC diagnostic push | ||
2280 | 28 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2281 | 27 | #include <gtest/gtest.h> | 29 | #include <gtest/gtest.h> |
2282 | 30 | #pragma GCC diagnostic pop | ||
2283 | 28 | 31 | ||
2284 | 29 | using namespace std; | 32 | using namespace std; |
2285 | 30 | using namespace unity::scopes; | 33 | using namespace unity::scopes; |
2286 | 31 | 34 | ||
2287 | === modified file 'test/gtest/scopes/internal/RuntimeImpl/RuntimeImpl_test.cpp' | |||
2288 | --- test/gtest/scopes/internal/RuntimeImpl/RuntimeImpl_test.cpp 2014-12-04 04:33:50 +0000 | |||
2289 | +++ test/gtest/scopes/internal/RuntimeImpl/RuntimeImpl_test.cpp 2017-01-16 06:43:13 +0000 | |||
2290 | @@ -25,7 +25,11 @@ | |||
2291 | 25 | 25 | ||
2292 | 26 | #include <boost/algorithm/string.hpp> | 26 | #include <boost/algorithm/string.hpp> |
2293 | 27 | #include <boost/filesystem.hpp> | 27 | #include <boost/filesystem.hpp> |
2294 | 28 | |||
2295 | 29 | #pragma GCC diagnostic push | ||
2296 | 30 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2297 | 28 | #include <gtest/gtest.h> | 31 | #include <gtest/gtest.h> |
2298 | 32 | #pragma GCC diagnostic pop | ||
2299 | 29 | 33 | ||
2300 | 30 | #include <fstream> | 34 | #include <fstream> |
2301 | 31 | 35 | ||
2302 | 32 | 36 | ||
2303 | === modified file 'test/gtest/scopes/internal/ScopeConfig/ScopeConfig_test.cpp' | |||
2304 | --- test/gtest/scopes/internal/ScopeConfig/ScopeConfig_test.cpp 2016-10-13 11:57:05 +0000 | |||
2305 | +++ test/gtest/scopes/internal/ScopeConfig/ScopeConfig_test.cpp 2017-01-16 06:43:13 +0000 | |||
2306 | @@ -23,7 +23,10 @@ | |||
2307 | 23 | #include <unity/UnityExceptions.h> | 23 | #include <unity/UnityExceptions.h> |
2308 | 24 | 24 | ||
2309 | 25 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. | 25 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. |
2310 | 26 | #pragma GCC diagnostic push | ||
2311 | 27 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2312 | 26 | #include <gtest/gtest.h> | 28 | #include <gtest/gtest.h> |
2313 | 29 | #pragma GCC diagnostic pop | ||
2314 | 27 | 30 | ||
2315 | 28 | using namespace unity::scopes; | 31 | using namespace unity::scopes; |
2316 | 29 | using namespace unity::scopes::internal; | 32 | using namespace unity::scopes::internal; |
2317 | @@ -65,7 +68,7 @@ | |||
2318 | 65 | EXPECT_TRUE(cfg.is_aggregator()); | 68 | EXPECT_TRUE(cfg.is_aggregator()); |
2319 | 66 | 69 | ||
2320 | 67 | auto attrs = cfg.appearance_attributes(); | 70 | auto attrs = cfg.appearance_attributes(); |
2322 | 68 | EXPECT_EQ(5, attrs.size()); | 71 | EXPECT_EQ(5u, attrs.size()); |
2323 | 69 | EXPECT_TRUE(attrs["arbitrary_key"].get_bool()); | 72 | EXPECT_TRUE(attrs["arbitrary_key"].get_bool()); |
2324 | 70 | EXPECT_EQ("bar", attrs["another_one"].get_string()); | 73 | EXPECT_EQ("bar", attrs["another_one"].get_string()); |
2325 | 71 | EXPECT_EQ(11, attrs["num_key"].get_int()); | 74 | EXPECT_EQ(11, attrs["num_key"].get_int()); |
2326 | @@ -97,7 +100,7 @@ | |||
2327 | 97 | EXPECT_EQ(0, cfg.version()); | 100 | EXPECT_EQ(0, cfg.version()); |
2328 | 98 | EXPECT_FALSE(cfg.is_aggregator()); | 101 | EXPECT_FALSE(cfg.is_aggregator()); |
2329 | 99 | 102 | ||
2331 | 100 | EXPECT_EQ(0, cfg.appearance_attributes().size()); | 103 | EXPECT_EQ(0u, cfg.appearance_attributes().size()); |
2332 | 101 | 104 | ||
2333 | 102 | // Optional items that throw if not set | 105 | // Optional items that throw if not set |
2334 | 103 | 106 | ||
2335 | @@ -137,13 +140,13 @@ | |||
2336 | 137 | TEST(ScopeConfig, empty_scope_ids) | 140 | TEST(ScopeConfig, empty_scope_ids) |
2337 | 138 | { | 141 | { |
2338 | 139 | ScopeConfig cfg(EMPTY_CHILD_IDS); | 142 | ScopeConfig cfg(EMPTY_CHILD_IDS); |
2340 | 140 | EXPECT_EQ(cfg.child_scope_ids().size(), 0); | 143 | EXPECT_EQ(0u, cfg.child_scope_ids().size()); |
2341 | 141 | } | 144 | } |
2342 | 142 | 145 | ||
2343 | 143 | TEST(ScopeConfig, single_scope_id) | 146 | TEST(ScopeConfig, single_scope_id) |
2344 | 144 | { | 147 | { |
2345 | 145 | ScopeConfig cfg(SINGLE_CHILD_ID); | 148 | ScopeConfig cfg(SINGLE_CHILD_ID); |
2347 | 146 | EXPECT_EQ(cfg.child_scope_ids().size(), 1); | 149 | EXPECT_EQ(1u, cfg.child_scope_ids().size()); |
2348 | 147 | } | 150 | } |
2349 | 148 | 151 | ||
2350 | 149 | TEST(ScopeConfig, bad_timeout) | 152 | TEST(ScopeConfig, bad_timeout) |
2351 | @@ -206,13 +209,13 @@ | |||
2352 | 206 | TEST(ScopeConfig, empty_keywords) | 209 | TEST(ScopeConfig, empty_keywords) |
2353 | 207 | { | 210 | { |
2354 | 208 | ScopeConfig cfg(EMPTY_KEYWORDS); | 211 | ScopeConfig cfg(EMPTY_KEYWORDS); |
2356 | 209 | EXPECT_EQ(cfg.keywords().size(), 0); | 212 | EXPECT_EQ(0u, cfg.keywords().size()); |
2357 | 210 | } | 213 | } |
2358 | 211 | 214 | ||
2359 | 212 | TEST(ScopeConfig, single_keyword) | 215 | TEST(ScopeConfig, single_keyword) |
2360 | 213 | { | 216 | { |
2361 | 214 | ScopeConfig cfg(SINGLE_KEYWORD); | 217 | ScopeConfig cfg(SINGLE_KEYWORD); |
2363 | 215 | EXPECT_EQ(cfg.keywords().size(), 1); | 218 | EXPECT_EQ(1u, cfg.keywords().size()); |
2364 | 216 | } | 219 | } |
2365 | 217 | 220 | ||
2366 | 218 | TEST(ScopeConfig, empty_display_name) | 221 | TEST(ScopeConfig, empty_display_name) |
2367 | 219 | 222 | ||
2368 | === modified file 'test/gtest/scopes/internal/ScopeLoader/ScopeLoader_test.cpp' | |||
2369 | --- test/gtest/scopes/internal/ScopeLoader/ScopeLoader_test.cpp 2014-08-28 00:20:56 +0000 | |||
2370 | +++ test/gtest/scopes/internal/ScopeLoader/ScopeLoader_test.cpp 2017-01-16 06:43:13 +0000 | |||
2371 | @@ -21,7 +21,10 @@ | |||
2372 | 21 | #include <unity/scopes/internal/ScopeLoader.h> | 21 | #include <unity/scopes/internal/ScopeLoader.h> |
2373 | 22 | #include <unity/UnityExceptions.h> | 22 | #include <unity/UnityExceptions.h> |
2374 | 23 | 23 | ||
2375 | 24 | #pragma GCC diagnostic push | ||
2376 | 25 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2377 | 24 | #include <gtest/gtest.h> | 26 | #include <gtest/gtest.h> |
2378 | 27 | #pragma GCC diagnostic pop | ||
2379 | 25 | 28 | ||
2380 | 26 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. | 29 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. |
2381 | 27 | #include "Counters.h" | 30 | #include "Counters.h" |
2382 | 28 | 31 | ||
2383 | === modified file 'test/gtest/scopes/internal/ScopeMetadataImpl/ScopeMetadataImpl_test.cpp' | |||
2384 | --- test/gtest/scopes/internal/ScopeMetadataImpl/ScopeMetadataImpl_test.cpp 2015-01-27 12:46:11 +0000 | |||
2385 | +++ test/gtest/scopes/internal/ScopeMetadataImpl/ScopeMetadataImpl_test.cpp 2017-01-16 06:43:13 +0000 | |||
2386 | @@ -25,7 +25,10 @@ | |||
2387 | 25 | #include <unity/UnityExceptions.h> | 25 | #include <unity/UnityExceptions.h> |
2388 | 26 | 26 | ||
2389 | 27 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. | 27 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. |
2390 | 28 | #pragma GCC diagnostic push | ||
2391 | 29 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2392 | 28 | #include <gtest/gtest.h> | 30 | #include <gtest/gtest.h> |
2393 | 31 | #pragma GCC diagnostic pop | ||
2394 | 29 | 32 | ||
2395 | 30 | using namespace std; | 33 | using namespace std; |
2396 | 31 | using namespace unity; | 34 | using namespace unity; |
2397 | @@ -61,7 +64,7 @@ | |||
2398 | 61 | EXPECT_EQ("display_name", m.display_name()); | 64 | EXPECT_EQ("display_name", m.display_name()); |
2399 | 62 | EXPECT_EQ("description", m.description()); | 65 | EXPECT_EQ("description", m.description()); |
2400 | 63 | EXPECT_EQ("author", m.author()); | 66 | EXPECT_EQ("author", m.author()); |
2402 | 64 | EXPECT_EQ(0, m.appearance_attributes().size()); | 67 | EXPECT_EQ(0u, m.appearance_attributes().size()); |
2403 | 65 | EXPECT_EQ(ScopeMetadata::ResultsTtlType::Medium, m.results_ttl_type()); | 68 | EXPECT_EQ(ScopeMetadata::ResultsTtlType::Medium, m.results_ttl_type()); |
2404 | 66 | 69 | ||
2405 | 67 | // Check that optional fields that are not set throw | 70 | // Check that optional fields that are not set throw |
2406 | @@ -144,7 +147,7 @@ | |||
2407 | 144 | EXPECT_EQ("display_name", mi2->display_name()); | 147 | EXPECT_EQ("display_name", mi2->display_name()); |
2408 | 145 | EXPECT_EQ("description", mi2->description()); | 148 | EXPECT_EQ("description", mi2->description()); |
2409 | 146 | EXPECT_EQ("author", mi2->author()); | 149 | EXPECT_EQ("author", mi2->author()); |
2411 | 147 | EXPECT_EQ(0, mi2->appearance_attributes().size()); | 150 | EXPECT_EQ(0u, mi2->appearance_attributes().size()); |
2412 | 148 | EXPECT_EQ(ScopeMetadata::ResultsTtlType::Medium, mi2->results_ttl_type()); | 151 | EXPECT_EQ(ScopeMetadata::ResultsTtlType::Medium, mi2->results_ttl_type()); |
2413 | 149 | EXPECT_EQ(0, mi2->version()); | 152 | EXPECT_EQ(0, mi2->version()); |
2414 | 150 | 153 | ||
2415 | 151 | 154 | ||
2416 | === modified file 'test/gtest/scopes/internal/SettingsDB/SettingsDB_test.cpp' | |||
2417 | --- test/gtest/scopes/internal/SettingsDB/SettingsDB_test.cpp 2016-03-15 04:36:08 +0000 | |||
2418 | +++ test/gtest/scopes/internal/SettingsDB/SettingsDB_test.cpp 2017-01-16 06:43:13 +0000 | |||
2419 | @@ -24,7 +24,11 @@ | |||
2420 | 24 | 24 | ||
2421 | 25 | #include <boost/algorithm/string.hpp> | 25 | #include <boost/algorithm/string.hpp> |
2422 | 26 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. | 26 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. |
2423 | 27 | #pragma GCC diagnostic push | ||
2424 | 28 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2425 | 27 | #include <gtest/gtest.h> | 29 | #include <gtest/gtest.h> |
2426 | 30 | #pragma GCC diagnostic pop | ||
2427 | 31 | |||
2428 | 28 | #include <fcntl.h> | 32 | #include <fcntl.h> |
2429 | 29 | #include <ctime> | 33 | #include <ctime> |
2430 | 30 | #include <thread> | 34 | #include <thread> |
2431 | @@ -91,7 +95,7 @@ | |||
2432 | 91 | auto db = SettingsDB::create_from_ini_file(db_name, schema); | 95 | auto db = SettingsDB::create_from_ini_file(db_name, schema); |
2433 | 92 | 96 | ||
2434 | 93 | // If db doesn't exist, default values are returned. | 97 | // If db doesn't exist, default values are returned. |
2436 | 94 | EXPECT_EQ(4, db->settings().size()); | 98 | EXPECT_EQ(4u, db->settings().size()); |
2437 | 95 | EXPECT_EQ("London", db->settings()["locationSetting"].get_string()); | 99 | EXPECT_EQ("London", db->settings()["locationSetting"].get_string()); |
2438 | 96 | EXPECT_EQ(1, db->settings()["unitTempSetting"].get_int()); | 100 | EXPECT_EQ(1, db->settings()["unitTempSetting"].get_int()); |
2439 | 97 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); | 101 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); |
2440 | @@ -101,7 +105,7 @@ | |||
2441 | 101 | write_db("db_empty.ini"); | 105 | write_db("db_empty.ini"); |
2442 | 102 | 106 | ||
2443 | 103 | // Default values must still be there. | 107 | // Default values must still be there. |
2445 | 104 | EXPECT_EQ(4, db->settings().size()); | 108 | EXPECT_EQ(4u, db->settings().size()); |
2446 | 105 | EXPECT_EQ("London", db->settings()["locationSetting"].get_string()); | 109 | EXPECT_EQ("London", db->settings()["locationSetting"].get_string()); |
2447 | 106 | EXPECT_EQ(1, db->settings()["unitTempSetting"].get_int()); | 110 | EXPECT_EQ(1, db->settings()["unitTempSetting"].get_int()); |
2448 | 107 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); | 111 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); |
2449 | @@ -111,7 +115,7 @@ | |||
2450 | 111 | write_db("db_unknown_setting.ini"); | 115 | write_db("db_unknown_setting.ini"); |
2451 | 112 | 116 | ||
2452 | 113 | // Default values must still be there. | 117 | // Default values must still be there. |
2454 | 114 | EXPECT_EQ(4, db->settings().size()); | 118 | EXPECT_EQ(4u, db->settings().size()); |
2455 | 115 | EXPECT_EQ("London", db->settings()["locationSetting"].get_string()); | 119 | EXPECT_EQ("London", db->settings()["locationSetting"].get_string()); |
2456 | 116 | EXPECT_EQ(1, db->settings()["unitTempSetting"].get_int()); | 120 | EXPECT_EQ(1, db->settings()["unitTempSetting"].get_int()); |
2457 | 117 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); | 121 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); |
2458 | @@ -119,7 +123,7 @@ | |||
2459 | 119 | 123 | ||
2460 | 120 | // Change the location. | 124 | // Change the location. |
2461 | 121 | write_db("db_location.ini"); | 125 | write_db("db_location.ini"); |
2463 | 122 | EXPECT_EQ(4, db->settings().size()); | 126 | EXPECT_EQ(4u, db->settings().size()); |
2464 | 123 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); | 127 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); |
2465 | 124 | EXPECT_EQ(1, db->settings()["unitTempSetting"].get_int()); | 128 | EXPECT_EQ(1, db->settings()["unitTempSetting"].get_int()); |
2466 | 125 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); | 129 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); |
2467 | @@ -127,7 +131,7 @@ | |||
2468 | 127 | 131 | ||
2469 | 128 | // Change the unit. | 132 | // Change the unit. |
2470 | 129 | write_db("db_loctemp.ini"); | 133 | write_db("db_loctemp.ini"); |
2472 | 130 | EXPECT_EQ(4, db->settings().size()); | 134 | EXPECT_EQ(4u, db->settings().size()); |
2473 | 131 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); | 135 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); |
2474 | 132 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); | 136 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); |
2475 | 133 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); | 137 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); |
2476 | @@ -135,7 +139,7 @@ | |||
2477 | 135 | 139 | ||
2478 | 136 | // Change the age. | 140 | // Change the age. |
2479 | 137 | write_db("db_loctempage.ini"); | 141 | write_db("db_loctempage.ini"); |
2481 | 138 | EXPECT_EQ(4, db->settings().size()); | 142 | EXPECT_EQ(4u, db->settings().size()); |
2482 | 139 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); | 143 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); |
2483 | 140 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); | 144 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); |
2484 | 141 | EXPECT_EQ(42.0, db->settings()["ageSetting"].get_double()); | 145 | EXPECT_EQ(42.0, db->settings()["ageSetting"].get_double()); |
2485 | @@ -144,7 +148,7 @@ | |||
2486 | 144 | // Call settings again. This causes state_changed_ in the implementation | 148 | // Call settings again. This causes state_changed_ in the implementation |
2487 | 145 | // to remain false because the generation count hasn't changed, meaning | 149 | // to remain false because the generation count hasn't changed, meaning |
2488 | 146 | // that we must see the same unchanged values as last time. | 150 | // that we must see the same unchanged values as last time. |
2490 | 147 | EXPECT_EQ(4, db->settings().size()); | 151 | EXPECT_EQ(4u, db->settings().size()); |
2491 | 148 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); | 152 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); |
2492 | 149 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); | 153 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); |
2493 | 150 | EXPECT_EQ(42, db->settings()["ageSetting"].get_double()); | 154 | EXPECT_EQ(42, db->settings()["ageSetting"].get_double()); |
2494 | @@ -152,7 +156,7 @@ | |||
2495 | 152 | 156 | ||
2496 | 153 | // Change enabled boolean. | 157 | // Change enabled boolean. |
2497 | 154 | write_db("db_loctempageenabled.ini"); | 158 | write_db("db_loctempageenabled.ini"); |
2499 | 155 | EXPECT_EQ(4, db->settings().size()); | 159 | EXPECT_EQ(4u, db->settings().size()); |
2500 | 156 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); | 160 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); |
2501 | 157 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); | 161 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); |
2502 | 158 | EXPECT_EQ(42, db->settings()["ageSetting"].get_double()); | 162 | EXPECT_EQ(42, db->settings()["ageSetting"].get_double()); |
2503 | @@ -167,7 +171,7 @@ | |||
2504 | 167 | auto db = SettingsDB::create_from_ini_file(db_name, schema); | 171 | auto db = SettingsDB::create_from_ini_file(db_name, schema); |
2505 | 168 | 172 | ||
2506 | 169 | // Check that we now can see only the other two values. (DB doesn't exist yet.) | 173 | // Check that we now can see only the other two values. (DB doesn't exist yet.) |
2508 | 170 | EXPECT_EQ(2, db->settings().size()); | 174 | EXPECT_EQ(2u, db->settings().size()); |
2509 | 171 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); | 175 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); |
2510 | 172 | EXPECT_TRUE(db->settings()["enabledSetting"].get_bool()); | 176 | EXPECT_TRUE(db->settings()["enabledSetting"].get_bool()); |
2511 | 173 | 177 | ||
2512 | @@ -175,7 +179,7 @@ | |||
2513 | 175 | write_db("db_loctemp.ini"); | 179 | write_db("db_loctemp.ini"); |
2514 | 176 | 180 | ||
2515 | 177 | // Check that they are correct | 181 | // Check that they are correct |
2517 | 178 | EXPECT_EQ(4, db->settings().size()); | 182 | EXPECT_EQ(4u, db->settings().size()); |
2518 | 179 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); | 183 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); |
2519 | 180 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); | 184 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); |
2520 | 181 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); | 185 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); |
2521 | @@ -193,7 +197,7 @@ | |||
2522 | 193 | write_db("db_loctemp.ini"); | 197 | write_db("db_loctemp.ini"); |
2523 | 194 | 198 | ||
2524 | 195 | // Check that they are correct. | 199 | // Check that they are correct. |
2526 | 196 | EXPECT_EQ(4, db->settings().size()); | 200 | EXPECT_EQ(4u, db->settings().size()); |
2527 | 197 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); | 201 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); |
2528 | 198 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); | 202 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); |
2529 | 199 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); | 203 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); |
2530 | @@ -203,7 +207,7 @@ | |||
2531 | 203 | write_db("db_loctemp_bad_age.ini"); | 207 | write_db("db_loctemp_bad_age.ini"); |
2532 | 204 | 208 | ||
2533 | 205 | // Check that nothing has changed. | 209 | // Check that nothing has changed. |
2535 | 206 | EXPECT_EQ(4, db->settings().size()); | 210 | EXPECT_EQ(4u, db->settings().size()); |
2536 | 207 | EXPECT_EQ("Paris", db->settings()["locationSetting"].get_string()); | 211 | EXPECT_EQ("Paris", db->settings()["locationSetting"].get_string()); |
2537 | 208 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); | 212 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); |
2538 | 209 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); | 213 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); |
2539 | @@ -220,12 +224,12 @@ | |||
2540 | 220 | auto db = SettingsDB::create_from_ini_file(db_name, schema); | 224 | auto db = SettingsDB::create_from_ini_file(db_name, schema); |
2541 | 221 | 225 | ||
2542 | 222 | // If db doesn't exist, default values are returned. | 226 | // If db doesn't exist, default values are returned. |
2544 | 223 | EXPECT_EQ(1, db->settings().size()); | 227 | EXPECT_EQ(1u, db->settings().size()); |
2545 | 224 | EXPECT_EQ("çš„", db->settings()["locationSetting"].get_string()); | 228 | EXPECT_EQ("çš„", db->settings()["locationSetting"].get_string()); |
2546 | 225 | 229 | ||
2547 | 226 | // Change the location. | 230 | // Change the location. |
2548 | 227 | write_db("db_chinese_location.ini"); | 231 | write_db("db_chinese_location.ini"); |
2550 | 228 | EXPECT_EQ(1, db->settings().size()); | 232 | EXPECT_EQ(1u, db->settings().size()); |
2551 | 229 | EXPECT_EQ("丈", db->settings()["locationSetting"].get_string()); | 233 | EXPECT_EQ("丈", db->settings()["locationSetting"].get_string()); |
2552 | 230 | } | 234 | } |
2553 | 231 | } | 235 | } |
2554 | @@ -239,7 +243,7 @@ | |||
2555 | 239 | auto db = SettingsDB::create_from_ini_file(db_name, schema); | 243 | auto db = SettingsDB::create_from_ini_file(db_name, schema); |
2556 | 240 | 244 | ||
2557 | 241 | // If db doesn't exist, default values are returned. | 245 | // If db doesn't exist, default values are returned. |
2559 | 242 | EXPECT_EQ(4, db->settings().size()); | 246 | EXPECT_EQ(4u, db->settings().size()); |
2560 | 243 | EXPECT_EQ("London", db->settings()["locationSetting"].get_string()); | 247 | EXPECT_EQ("London", db->settings()["locationSetting"].get_string()); |
2561 | 244 | EXPECT_EQ(1, db->settings()["unitTempSetting"].get_int()); | 248 | EXPECT_EQ(1, db->settings()["unitTempSetting"].get_int()); |
2562 | 245 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); | 249 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); |
2563 | @@ -249,7 +253,7 @@ | |||
2564 | 249 | write_db("db_loctempageenabled.ini"); | 253 | write_db("db_loctempageenabled.ini"); |
2565 | 250 | 254 | ||
2566 | 251 | // Settings should be updated. | 255 | // Settings should be updated. |
2568 | 252 | EXPECT_EQ(4, db->settings().size()); | 256 | EXPECT_EQ(4u, db->settings().size()); |
2569 | 253 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); | 257 | EXPECT_EQ("New York", db->settings()["locationSetting"].get_string()); |
2570 | 254 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); | 258 | EXPECT_EQ(0, db->settings()["unitTempSetting"].get_int()); |
2571 | 255 | EXPECT_EQ(42, db->settings()["ageSetting"].get_double()); | 259 | EXPECT_EQ(42, db->settings()["ageSetting"].get_double()); |
2572 | @@ -259,7 +263,7 @@ | |||
2573 | 259 | unlink(db_name.c_str()); | 263 | unlink(db_name.c_str()); |
2574 | 260 | 264 | ||
2575 | 261 | // Default values should come back. | 265 | // Default values should come back. |
2577 | 262 | EXPECT_EQ(4, db->settings().size()); | 266 | EXPECT_EQ(4u, db->settings().size()); |
2578 | 263 | EXPECT_EQ("London", db->settings()["locationSetting"].get_string()); | 267 | EXPECT_EQ("London", db->settings()["locationSetting"].get_string()); |
2579 | 264 | EXPECT_EQ(1, db->settings()["unitTempSetting"].get_int()); | 268 | EXPECT_EQ(1, db->settings()["unitTempSetting"].get_int()); |
2580 | 265 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); | 269 | EXPECT_EQ(23, db->settings()["ageSetting"].get_double()); |
2581 | @@ -290,12 +294,12 @@ | |||
2582 | 290 | auto db = SettingsDB::create_from_json_string(db_name, ok_schema); | 294 | auto db = SettingsDB::create_from_json_string(db_name, ok_schema); |
2583 | 291 | 295 | ||
2584 | 292 | // If db doesn't exist, default values are returned. | 296 | // If db doesn't exist, default values are returned. |
2586 | 293 | EXPECT_EQ(1, db->settings().size()); | 297 | EXPECT_EQ(1u, db->settings().size()); |
2587 | 294 | EXPECT_EQ("London", db->settings()["location"].get_string()); | 298 | EXPECT_EQ("London", db->settings()["location"].get_string()); |
2588 | 295 | 299 | ||
2589 | 296 | // Change the location. | 300 | // Change the location. |
2590 | 297 | write_db("db_location_json.ini"); | 301 | write_db("db_location_json.ini"); |
2592 | 298 | EXPECT_EQ(1, db->settings().size()); | 302 | EXPECT_EQ(1u, db->settings().size()); |
2593 | 299 | EXPECT_EQ("New York", db->settings()["location"].get_string()); | 303 | EXPECT_EQ("New York", db->settings()["location"].get_string()); |
2594 | 300 | } | 304 | } |
2595 | 301 | } | 305 | } |
2596 | @@ -363,7 +367,7 @@ | |||
2597 | 363 | auto schema = TEST_SRC_DIR "/schema.ini"; | 367 | auto schema = TEST_SRC_DIR "/schema.ini"; |
2598 | 364 | auto db = SettingsDB::create_from_ini_file(db_name, schema); | 368 | auto db = SettingsDB::create_from_ini_file(db_name, schema); |
2599 | 365 | 369 | ||
2601 | 366 | EXPECT_EQ(4, db->settings().size()); | 370 | EXPECT_EQ(4u, db->settings().size()); |
2602 | 367 | EXPECT_EQ("Munich", db->settings()["locationSetting"].get_string()); | 371 | EXPECT_EQ("Munich", db->settings()["locationSetting"].get_string()); |
2603 | 368 | 372 | ||
2604 | 369 | 373 | ||
2605 | @@ -381,7 +385,7 @@ | |||
2606 | 381 | } | 385 | } |
2607 | 382 | catch (ResourceException const& e) | 386 | catch (ResourceException const& e) |
2608 | 383 | { | 387 | { |
2610 | 384 | boost::regex r("unity::ResourceException: unity::FileException: Could not load ini file .*: Key file contains line 'x' which is not a key-value pair, group, or comment \\(errno = 1\\)"); | 388 | boost::regex r("unity::ResourceException: unity::FileException: Could not load ini file .*: Key file contains line .*"); |
2611 | 385 | EXPECT_TRUE(boost::regex_match(e.what(), r)) << e.what(); | 389 | EXPECT_TRUE(boost::regex_match(e.what(), r)) << e.what(); |
2612 | 386 | } | 390 | } |
2613 | 387 | } | 391 | } |
2614 | 388 | 392 | ||
2615 | === modified file 'test/gtest/scopes/internal/ThreadPool/ThreadPool_test.cpp' | |||
2616 | --- test/gtest/scopes/internal/ThreadPool/ThreadPool_test.cpp 2014-09-22 05:50:56 +0000 | |||
2617 | +++ test/gtest/scopes/internal/ThreadPool/ThreadPool_test.cpp 2017-01-16 06:43:13 +0000 | |||
2618 | @@ -20,7 +20,11 @@ | |||
2619 | 20 | 20 | ||
2620 | 21 | #include <unity/UnityExceptions.h> | 21 | #include <unity/UnityExceptions.h> |
2621 | 22 | 22 | ||
2622 | 23 | #pragma GCC diagnostic push | ||
2623 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2624 | 23 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
2625 | 26 | #pragma GCC diagnostic pop | ||
2626 | 27 | |||
2627 | 24 | #include <valgrind/valgrind.h> | 28 | #include <valgrind/valgrind.h> |
2628 | 25 | 29 | ||
2629 | 26 | using namespace std; | 30 | using namespace std; |
2630 | 27 | 31 | ||
2631 | === modified file 'test/gtest/scopes/internal/ThreadSafeQueue/ThreadSafeQueue_test.cpp' | |||
2632 | --- test/gtest/scopes/internal/ThreadSafeQueue/ThreadSafeQueue_test.cpp 2014-09-08 05:55:39 +0000 | |||
2633 | +++ test/gtest/scopes/internal/ThreadSafeQueue/ThreadSafeQueue_test.cpp 2017-01-16 06:43:13 +0000 | |||
2634 | @@ -18,7 +18,10 @@ | |||
2635 | 18 | 18 | ||
2636 | 19 | #include <unity/scopes/internal/ThreadSafeQueue.h> | 19 | #include <unity/scopes/internal/ThreadSafeQueue.h> |
2637 | 20 | 20 | ||
2638 | 21 | #pragma GCC diagnostic push | ||
2639 | 22 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2640 | 21 | #include <gtest/gtest.h> | 23 | #include <gtest/gtest.h> |
2641 | 24 | #pragma GCC diagnostic pop | ||
2642 | 22 | 25 | ||
2643 | 23 | #include <future> | 26 | #include <future> |
2644 | 24 | 27 | ||
2645 | 25 | 28 | ||
2646 | === modified file 'test/gtest/scopes/internal/UniqueID/UniqueID_test.cpp' | |||
2647 | --- test/gtest/scopes/internal/UniqueID/UniqueID_test.cpp 2014-02-25 12:08:41 +0000 | |||
2648 | +++ test/gtest/scopes/internal/UniqueID/UniqueID_test.cpp 2017-01-16 06:43:13 +0000 | |||
2649 | @@ -18,7 +18,10 @@ | |||
2650 | 18 | 18 | ||
2651 | 19 | #include <unity/scopes/internal/UniqueID.h> | 19 | #include <unity/scopes/internal/UniqueID.h> |
2652 | 20 | 20 | ||
2653 | 21 | #pragma GCC diagnostic push | ||
2654 | 22 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2655 | 21 | #include <gtest/gtest.h> | 23 | #include <gtest/gtest.h> |
2656 | 24 | #pragma GCC diagnostic pop | ||
2657 | 22 | 25 | ||
2658 | 23 | using namespace std; | 26 | using namespace std; |
2659 | 24 | using namespace unity::scopes::internal; | 27 | using namespace unity::scopes::internal; |
2660 | 25 | 28 | ||
2661 | === modified file 'test/gtest/scopes/internal/Utils/Utils_test.cpp' | |||
2662 | --- test/gtest/scopes/internal/Utils/Utils_test.cpp 2016-10-07 15:42:53 +0000 | |||
2663 | +++ test/gtest/scopes/internal/Utils/Utils_test.cpp 2017-01-16 06:43:13 +0000 | |||
2664 | @@ -18,9 +18,14 @@ | |||
2665 | 18 | 18 | ||
2666 | 19 | #include <unity/scopes/internal/Utils.h> | 19 | #include <unity/scopes/internal/Utils.h> |
2667 | 20 | 20 | ||
2668 | 21 | #include <unity/UnityExceptions.h> | ||
2669 | 22 | |||
2670 | 21 | #include <boost/filesystem.hpp> | 23 | #include <boost/filesystem.hpp> |
2671 | 24 | |||
2672 | 25 | #pragma GCC diagnostic push | ||
2673 | 26 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2674 | 22 | #include <gtest/gtest.h> | 27 | #include <gtest/gtest.h> |
2676 | 23 | #include <unity/UnityExceptions.h> | 28 | #pragma GCC diagnostic pop |
2677 | 24 | 29 | ||
2678 | 25 | using namespace unity::scopes; | 30 | using namespace unity::scopes; |
2679 | 26 | using namespace unity::scopes::internal; | 31 | using namespace unity::scopes::internal; |
2680 | @@ -39,13 +44,24 @@ | |||
2681 | 39 | 44 | ||
2682 | 40 | TEST(Utils, uncamelcase_turkish) | 45 | TEST(Utils, uncamelcase_turkish) |
2683 | 41 | { | 46 | { |
2685 | 42 | char *old_locale = strdup(getenv("LC_ALL")); | 47 | string old_locale; |
2686 | 48 | char const* p = getenv("LC_ALL"); | ||
2687 | 49 | if (p) | ||
2688 | 50 | { | ||
2689 | 51 | old_locale = p; | ||
2690 | 52 | } | ||
2691 | 43 | setenv("LC_ALL", "tr_TR.UTF-8", 1); | 53 | setenv("LC_ALL", "tr_TR.UTF-8", 1); |
2692 | 44 | 54 | ||
2693 | 45 | EXPECT_EQ("small-i", uncamelcase("smallI")); | 55 | EXPECT_EQ("small-i", uncamelcase("smallI")); |
2694 | 46 | 56 | ||
2697 | 47 | setenv("LC_ALL", old_locale, 1); | 57 | if (!old_locale.empty()) |
2698 | 48 | free(old_locale); | 58 | { |
2699 | 59 | setenv("LC_ALL", old_locale.c_str(), 1); | ||
2700 | 60 | } | ||
2701 | 61 | else | ||
2702 | 62 | { | ||
2703 | 63 | unsetenv("LC_ALL"); | ||
2704 | 64 | } | ||
2705 | 49 | } | 65 | } |
2706 | 50 | 66 | ||
2707 | 51 | TEST(Utils, convert_to) | 67 | TEST(Utils, convert_to) |
2708 | @@ -170,7 +186,7 @@ | |||
2709 | 170 | 186 | ||
2710 | 171 | // Test argument splitting | 187 | // Test argument splitting |
2711 | 172 | auto exec_args = split_exec_args("test", "/path\\ to/exec' 'file arg \"arg 2\" arg' '3 arg\\ 4"); | 188 | auto exec_args = split_exec_args("test", "/path\\ to/exec' 'file arg \"arg 2\" arg' '3 arg\\ 4"); |
2713 | 173 | ASSERT_EQ(5, exec_args.size()); | 189 | ASSERT_EQ(5u, exec_args.size()); |
2714 | 174 | EXPECT_STREQ("\"/path to/exec file\"", exec_args[0].c_str()); | 190 | EXPECT_STREQ("\"/path to/exec file\"", exec_args[0].c_str()); |
2715 | 175 | EXPECT_STREQ("arg", exec_args[1].c_str()); | 191 | EXPECT_STREQ("arg", exec_args[1].c_str()); |
2716 | 176 | EXPECT_STREQ("\"arg 2\"", exec_args[2].c_str()); | 192 | EXPECT_STREQ("\"arg 2\"", exec_args[2].c_str()); |
2717 | 177 | 193 | ||
2718 | === modified file 'test/gtest/scopes/internal/gobj_ptr/gobj_ptr_test.cpp' | |||
2719 | --- test/gtest/scopes/internal/gobj_ptr/gobj_ptr_test.cpp 2016-03-15 04:43:56 +0000 | |||
2720 | +++ test/gtest/scopes/internal/gobj_ptr/gobj_ptr_test.cpp 2017-01-16 06:43:13 +0000 | |||
2721 | @@ -22,7 +22,11 @@ | |||
2722 | 22 | 22 | ||
2723 | 23 | #include <unity/scopes/internal/gobj_memory.h> | 23 | #include <unity/scopes/internal/gobj_memory.h> |
2724 | 24 | #include <glib-object.h> | 24 | #include <glib-object.h> |
2725 | 25 | |||
2726 | 26 | #pragma GCC diagnostic push | ||
2727 | 27 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2728 | 25 | #include <gtest/gtest.h> | 28 | #include <gtest/gtest.h> |
2729 | 29 | #pragma GCC diagnostic pop | ||
2730 | 26 | 30 | ||
2731 | 27 | using namespace std; | 31 | using namespace std; |
2732 | 28 | using namespace unity::scopes::internal; | 32 | using namespace unity::scopes::internal; |
2733 | @@ -87,17 +91,17 @@ | |||
2734 | 87 | TEST(Gobj_ptr, refcount) | 91 | TEST(Gobj_ptr, refcount) |
2735 | 88 | { | 92 | { |
2736 | 89 | GObject* o = G_OBJECT(g_object_new(G_TYPE_OBJECT, nullptr)); | 93 | GObject* o = G_OBJECT(g_object_new(G_TYPE_OBJECT, nullptr)); |
2738 | 90 | EXPECT_EQ(1, o->ref_count); | 94 | EXPECT_EQ(1u, o->ref_count); |
2739 | 91 | g_object_ref(o); | 95 | g_object_ref(o); |
2740 | 92 | 96 | ||
2741 | 93 | { | 97 | { |
2743 | 94 | EXPECT_EQ(2, o->ref_count); | 98 | EXPECT_EQ(2u, o->ref_count); |
2744 | 95 | gobj_ptr<GObject> u(o); | 99 | gobj_ptr<GObject> u(o); |
2746 | 96 | EXPECT_EQ(2, o->ref_count); | 100 | EXPECT_EQ(2u, o->ref_count); |
2747 | 97 | // Now it dies and refcount is reduced. | 101 | // Now it dies and refcount is reduced. |
2748 | 98 | } | 102 | } |
2749 | 99 | 103 | ||
2751 | 100 | EXPECT_EQ(1, o->ref_count); | 104 | EXPECT_EQ(1u, o->ref_count); |
2752 | 101 | g_object_unref(o); | 105 | g_object_unref(o); |
2753 | 102 | } | 106 | } |
2754 | 103 | 107 | ||
2755 | @@ -105,14 +109,14 @@ | |||
2756 | 105 | { | 109 | { |
2757 | 106 | GObject* o = G_OBJECT(g_object_new(G_TYPE_OBJECT, nullptr)); | 110 | GObject* o = G_OBJECT(g_object_new(G_TYPE_OBJECT, nullptr)); |
2758 | 107 | gobj_ptr<GObject> u(o); | 111 | gobj_ptr<GObject> u(o); |
2760 | 108 | EXPECT_EQ(1, u->ref_count); | 112 | EXPECT_EQ(1u, u->ref_count); |
2761 | 109 | gobj_ptr<GObject> u2(u); | 113 | gobj_ptr<GObject> u2(u); |
2763 | 110 | EXPECT_EQ(2, u->ref_count); | 114 | EXPECT_EQ(2u, u->ref_count); |
2764 | 111 | gobj_ptr<GObject> u3 = u2; | 115 | gobj_ptr<GObject> u3 = u2; |
2766 | 112 | EXPECT_EQ(3, u->ref_count); | 116 | EXPECT_EQ(3u, u->ref_count); |
2767 | 113 | u3.reset(); | 117 | u3.reset(); |
2768 | 114 | u2.reset(); | 118 | u2.reset(); |
2770 | 115 | EXPECT_EQ(1, u->ref_count); | 119 | EXPECT_EQ(1u, u->ref_count); |
2771 | 116 | } | 120 | } |
2772 | 117 | 121 | ||
2773 | 118 | TEST(Gobj_ptr, swap) | 122 | TEST(Gobj_ptr, swap) |
2774 | 119 | 123 | ||
2775 | === modified file 'test/gtest/scopes/internal/safe_strerror/safe_strerror_test.cpp' | |||
2776 | --- test/gtest/scopes/internal/safe_strerror/safe_strerror_test.cpp 2014-11-17 01:29:26 +0000 | |||
2777 | +++ test/gtest/scopes/internal/safe_strerror/safe_strerror_test.cpp 2017-01-16 06:43:13 +0000 | |||
2778 | @@ -17,7 +17,11 @@ | |||
2779 | 17 | */ | 17 | */ |
2780 | 18 | 18 | ||
2781 | 19 | #include <unity/scopes/internal/safe_strerror.h> | 19 | #include <unity/scopes/internal/safe_strerror.h> |
2782 | 20 | |||
2783 | 21 | #pragma GCC diagnostic push | ||
2784 | 22 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2785 | 20 | #include <gtest/gtest.h> | 23 | #include <gtest/gtest.h> |
2786 | 24 | #pragma GCC diagnostic pop | ||
2787 | 21 | 25 | ||
2788 | 22 | using namespace unity::scopes::internal; | 26 | using namespace unity::scopes::internal; |
2789 | 23 | 27 | ||
2790 | 24 | 28 | ||
2791 | === modified file 'test/gtest/scopes/internal/smartscopes/HttpClient/HttpClient_test.cpp' | |||
2792 | --- test/gtest/scopes/internal/smartscopes/HttpClient/HttpClient_test.cpp 2015-01-16 06:13:57 +0000 | |||
2793 | +++ test/gtest/scopes/internal/smartscopes/HttpClient/HttpClient_test.cpp 2017-01-16 06:43:13 +0000 | |||
2794 | @@ -21,7 +21,11 @@ | |||
2795 | 21 | 21 | ||
2796 | 22 | #include "../RaiiServer.h" | 22 | #include "../RaiiServer.h" |
2797 | 23 | 23 | ||
2798 | 24 | #pragma GCC diagnostic push | ||
2799 | 25 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2800 | 24 | #include <gtest/gtest.h> | 26 | #include <gtest/gtest.h> |
2801 | 27 | #pragma GCC diagnostic pop | ||
2802 | 28 | |||
2803 | 25 | #include <memory> | 29 | #include <memory> |
2804 | 26 | #include <thread> | 30 | #include <thread> |
2805 | 27 | 31 | ||
2806 | 28 | 32 | ||
2807 | === modified file 'test/gtest/scopes/internal/smartscopes/SSConfig/SSConfig_test.cpp' | |||
2808 | --- test/gtest/scopes/internal/smartscopes/SSConfig/SSConfig_test.cpp 2014-07-25 07:29:19 +0000 | |||
2809 | +++ test/gtest/scopes/internal/smartscopes/SSConfig/SSConfig_test.cpp 2017-01-16 06:43:13 +0000 | |||
2810 | @@ -21,7 +21,10 @@ | |||
2811 | 21 | #include <unity/scopes/ScopeExceptions.h> | 21 | #include <unity/scopes/ScopeExceptions.h> |
2812 | 22 | #include <unity/UnityExceptions.h> | 22 | #include <unity/UnityExceptions.h> |
2813 | 23 | 23 | ||
2814 | 24 | #pragma GCC diagnostic push | ||
2815 | 25 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2816 | 24 | #include <gtest/gtest.h> | 26 | #include <gtest/gtest.h> |
2817 | 27 | #pragma GCC diagnostic pop | ||
2818 | 25 | 28 | ||
2819 | 26 | using namespace std; | 29 | using namespace std; |
2820 | 27 | using namespace unity; | 30 | using namespace unity; |
2821 | 28 | 31 | ||
2822 | === modified file 'test/gtest/scopes/internal/smartscopes/SmartScopesClient/SmartScopesClient_test.cpp' | |||
2823 | --- test/gtest/scopes/internal/smartscopes/SmartScopesClient/SmartScopesClient_test.cpp 2016-03-14 07:24:54 +0000 | |||
2824 | +++ test/gtest/scopes/internal/smartscopes/SmartScopesClient/SmartScopesClient_test.cpp 2017-01-16 06:43:13 +0000 | |||
2825 | @@ -29,7 +29,11 @@ | |||
2826 | 29 | 29 | ||
2827 | 30 | #include "../RaiiServer.h" | 30 | #include "../RaiiServer.h" |
2828 | 31 | 31 | ||
2829 | 32 | #pragma GCC diagnostic push | ||
2830 | 33 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2831 | 32 | #include <gtest/gtest.h> | 34 | #include <gtest/gtest.h> |
2832 | 35 | #pragma GCC diagnostic pop | ||
2833 | 36 | |||
2834 | 33 | #include <memory> | 37 | #include <memory> |
2835 | 34 | #include <thread> | 38 | #include <thread> |
2836 | 35 | 39 | ||
2837 | @@ -84,7 +88,7 @@ | |||
2838 | 84 | 88 | ||
2839 | 85 | // first try an invalid locale (should throw) | 89 | // first try an invalid locale (should throw) |
2840 | 86 | EXPECT_THROW(ssc_->get_remote_scopes(scopes, "test_FAIL", false), std::exception); | 90 | EXPECT_THROW(ssc_->get_remote_scopes(scopes, "test_FAIL", false), std::exception); |
2842 | 87 | ASSERT_EQ(0, scopes.size()); | 91 | ASSERT_EQ(0u, scopes.size()); |
2843 | 88 | 92 | ||
2844 | 89 | // now try an empty locale | 93 | // now try an empty locale |
2845 | 90 | EXPECT_TRUE(ssc_->get_remote_scopes(scopes, "", false)); | 94 | EXPECT_TRUE(ssc_->get_remote_scopes(scopes, "", false)); |
2846 | @@ -165,7 +169,7 @@ | |||
2847 | 165 | params = vm["parameters"].get_dict(); | 169 | params = vm["parameters"].get_dict(); |
2848 | 166 | EXPECT_TRUE(params["defaultValue"].get_bool()); | 170 | EXPECT_TRUE(params["defaultValue"].get_bool()); |
2849 | 167 | } | 171 | } |
2851 | 168 | ASSERT_EQ(4, scopes[2].keywords.size()); | 172 | ASSERT_EQ(4u, scopes[2].keywords.size()); |
2852 | 169 | EXPECT_NE(scopes[2].keywords.end(), scopes[2].keywords.find("music")); | 173 | EXPECT_NE(scopes[2].keywords.end(), scopes[2].keywords.find("music")); |
2853 | 170 | EXPECT_NE(scopes[2].keywords.end(), scopes[2].keywords.find("video")); | 174 | EXPECT_NE(scopes[2].keywords.end(), scopes[2].keywords.find("video")); |
2854 | 171 | EXPECT_NE(scopes[2].keywords.end(), scopes[2].keywords.find("news")); | 175 | EXPECT_NE(scopes[2].keywords.end(), scopes[2].keywords.find("news")); |
2855 | @@ -265,27 +269,27 @@ | |||
2856 | 265 | 269 | ||
2857 | 266 | // check filters | 270 | // check filters |
2858 | 267 | EXPECT_FALSE(filters.empty()); | 271 | EXPECT_FALSE(filters.empty()); |
2860 | 268 | EXPECT_EQ(filters.size(), 1); | 272 | EXPECT_EQ(1u, filters.size()); |
2861 | 269 | auto filter1 = filters.front(); | 273 | auto filter1 = filters.front(); |
2862 | 270 | auto option_filter = std::dynamic_pointer_cast<const OptionSelectorFilter>(filter1); | 274 | auto option_filter = std::dynamic_pointer_cast<const OptionSelectorFilter>(filter1); |
2863 | 271 | EXPECT_TRUE(option_filter != nullptr); | 275 | EXPECT_TRUE(option_filter != nullptr); |
2868 | 272 | EXPECT_EQ(option_filter->label(), "Label"); | 276 | EXPECT_EQ("Label", option_filter->label()); |
2869 | 273 | EXPECT_EQ(option_filter->id(), "sorting_primary_filter"); | 277 | EXPECT_EQ("sorting_primary_filter", option_filter->id()); |
2870 | 274 | EXPECT_EQ(option_filter->display_hints(), FilterBase::DisplayHints::Primary); | 278 | EXPECT_EQ(FilterBase::DisplayHints::Primary, option_filter->display_hints()); |
2871 | 275 | EXPECT_EQ(option_filter->multi_select(), false); | 279 | EXPECT_FALSE(option_filter->multi_select()); |
2872 | 276 | 280 | ||
2873 | 277 | auto options = option_filter->options(); | 281 | auto options = option_filter->options(); |
2879 | 278 | EXPECT_EQ(options.size(), 3); | 282 | EXPECT_EQ(3u, options.size()); |
2880 | 279 | EXPECT_EQ(options.front()->id(), "titlerank"); | 283 | EXPECT_EQ("titlerank", options.front()->id()); |
2881 | 280 | EXPECT_EQ(options.front()->label(), "Title rank"); | 284 | EXPECT_EQ("Title rank", options.front()->label()); |
2882 | 281 | EXPECT_EQ(options.back()->id(), "salesrank"); | 285 | EXPECT_EQ("salesrank", options.back()->id()); |
2883 | 282 | EXPECT_EQ(options.back()->label(), "Bestselling"); | 286 | EXPECT_EQ("Bestselling", options.back()->label()); |
2884 | 283 | 287 | ||
2885 | 284 | EXPECT_TRUE(option_filter->has_active_option(filter_state)); | 288 | EXPECT_TRUE(option_filter->has_active_option(filter_state)); |
2886 | 285 | auto active_options = option_filter->active_options(filter_state); | 289 | auto active_options = option_filter->active_options(filter_state); |
2887 | 286 | EXPECT_FALSE(active_options.empty()); | 290 | EXPECT_FALSE(active_options.empty()); |
2888 | 287 | auto active_option = *(active_options.begin()); | 291 | auto active_option = *(active_options.begin()); |
2890 | 288 | EXPECT_EQ(active_option->id(), "salesrank"); | 292 | EXPECT_EQ("salesrank", active_option->id()); |
2891 | 289 | } | 293 | } |
2892 | 290 | 294 | ||
2893 | 291 | TEST_F(SmartScopesClientTest, filter_groups) | 295 | TEST_F(SmartScopesClientTest, filter_groups) |
2894 | @@ -326,7 +330,7 @@ | |||
2895 | 326 | 330 | ||
2896 | 327 | // check filters | 331 | // check filters |
2897 | 328 | EXPECT_FALSE(filters.empty()); | 332 | EXPECT_FALSE(filters.empty()); |
2899 | 329 | EXPECT_EQ(filters.size(), 1); | 333 | EXPECT_EQ(1u, filters.size()); |
2900 | 330 | auto filter1 = filters.front(); | 334 | auto filter1 = filters.front(); |
2901 | 331 | auto option_filter = std::dynamic_pointer_cast<const OptionSelectorFilter>(filter1); | 335 | auto option_filter = std::dynamic_pointer_cast<const OptionSelectorFilter>(filter1); |
2902 | 332 | EXPECT_TRUE(option_filter != nullptr); | 336 | EXPECT_TRUE(option_filter != nullptr); |
2903 | @@ -334,19 +338,19 @@ | |||
2904 | 334 | EXPECT_TRUE(grp != nullptr); | 338 | EXPECT_TRUE(grp != nullptr); |
2905 | 335 | EXPECT_EQ("g1", grp->id()); | 339 | EXPECT_EQ("g1", grp->id()); |
2906 | 336 | EXPECT_EQ("Group 1", grp->label()); | 340 | EXPECT_EQ("Group 1", grp->label()); |
2911 | 337 | EXPECT_EQ(option_filter->label(), "Label"); | 341 | EXPECT_EQ("Label", option_filter->label()); |
2912 | 338 | EXPECT_EQ(option_filter->id(), "sorting_primary_filter"); | 342 | EXPECT_EQ("sorting_primary_filter", option_filter->id()); |
2913 | 339 | EXPECT_EQ(option_filter->display_hints(), FilterBase::DisplayHints::Primary); | 343 | EXPECT_EQ(FilterBase::DisplayHints::Primary, option_filter->display_hints()); |
2914 | 340 | EXPECT_EQ(option_filter->multi_select(), false); | 344 | EXPECT_FALSE(option_filter->multi_select()); |
2915 | 341 | 345 | ||
2916 | 342 | auto options = option_filter->options(); | 346 | auto options = option_filter->options(); |
2918 | 343 | EXPECT_EQ(options.size(), 2); | 347 | EXPECT_EQ(2u, options.size()); |
2919 | 344 | 348 | ||
2920 | 345 | EXPECT_TRUE(option_filter->has_active_option(filter_state)); | 349 | EXPECT_TRUE(option_filter->has_active_option(filter_state)); |
2921 | 346 | auto active_options = option_filter->active_options(filter_state); | 350 | auto active_options = option_filter->active_options(filter_state); |
2922 | 347 | EXPECT_FALSE(active_options.empty()); | 351 | EXPECT_FALSE(active_options.empty()); |
2923 | 348 | auto active_option = *(active_options.begin()); | 352 | auto active_option = *(active_options.begin()); |
2925 | 349 | EXPECT_EQ(active_option->id(), "salesrank"); | 353 | EXPECT_EQ("salesrank", active_option->id()); |
2926 | 350 | } | 354 | } |
2927 | 351 | 355 | ||
2928 | 352 | TEST_F(SmartScopesClientTest, userAgentHeader) | 356 | TEST_F(SmartScopesClientTest, userAgentHeader) |
2929 | 353 | 357 | ||
2930 | === modified file 'test/gtest/scopes/internal/smartscopes/smartscopesproxy/smartscopesproxy_test.cpp' | |||
2931 | --- test/gtest/scopes/internal/smartscopes/smartscopesproxy/smartscopesproxy_test.cpp 2015-04-29 17:01:02 +0000 | |||
2932 | +++ test/gtest/scopes/internal/smartscopes/smartscopesproxy/smartscopesproxy_test.cpp 2017-01-16 06:43:13 +0000 | |||
2933 | @@ -32,7 +32,11 @@ | |||
2934 | 32 | #include "../RaiiServer.h" | 32 | #include "../RaiiServer.h" |
2935 | 33 | 33 | ||
2936 | 34 | #include <memory> | 34 | #include <memory> |
2937 | 35 | |||
2938 | 36 | #pragma GCC diagnostic push | ||
2939 | 37 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
2940 | 35 | #include <gtest/gtest.h> | 38 | #include <gtest/gtest.h> |
2941 | 39 | #pragma GCC diagnostic pop | ||
2942 | 36 | 40 | ||
2943 | 37 | using namespace testing; | 41 | using namespace testing; |
2944 | 38 | using namespace unity::scopes; | 42 | using namespace unity::scopes; |
2945 | @@ -136,15 +140,15 @@ | |||
2946 | 136 | EXPECT_EQ("Dummy demo scope 3.", meta.description()); | 140 | EXPECT_EQ("Dummy demo scope 3.", meta.description()); |
2947 | 137 | EXPECT_EQ("Mr.Fake", meta.author()); | 141 | EXPECT_EQ("Mr.Fake", meta.author()); |
2948 | 138 | EXPECT_FALSE(meta.invisible()); | 142 | EXPECT_FALSE(meta.invisible()); |
2950 | 139 | EXPECT_EQ(4, meta.settings_definitions().size()); | 143 | EXPECT_EQ(4u, meta.settings_definitions().size()); |
2951 | 140 | EXPECT_EQ("unitTemp", meta.settings_definitions()[1].get_dict()["id"].get_string()); | 144 | EXPECT_EQ("unitTemp", meta.settings_definitions()[1].get_dict()["id"].get_string()); |
2952 | 141 | EXPECT_EQ("Temperature Units", meta.settings_definitions()[1].get_dict()["displayName"].get_string()); | 145 | EXPECT_EQ("Temperature Units", meta.settings_definitions()[1].get_dict()["displayName"].get_string()); |
2953 | 142 | EXPECT_EQ("list", meta.settings_definitions()[1].get_dict()["type"].get_string()); | 146 | EXPECT_EQ("list", meta.settings_definitions()[1].get_dict()["type"].get_string()); |
2954 | 143 | EXPECT_EQ(1, meta.settings_definitions()[1].get_dict()["defaultValue"].get_int()); | 147 | EXPECT_EQ(1, meta.settings_definitions()[1].get_dict()["defaultValue"].get_int()); |
2956 | 144 | EXPECT_EQ(2, meta.settings_definitions()[1].get_dict()["displayValues"].get_array().size()); | 148 | EXPECT_EQ(2u, meta.settings_definitions()[1].get_dict()["displayValues"].get_array().size()); |
2957 | 145 | EXPECT_EQ("Celsius", meta.settings_definitions()[1].get_dict()["displayValues"].get_array()[0].get_string()); | 149 | EXPECT_EQ("Celsius", meta.settings_definitions()[1].get_dict()["displayValues"].get_array()[0].get_string()); |
2958 | 146 | EXPECT_EQ("Fahrenheit", meta.settings_definitions()[1].get_dict()["displayValues"].get_array()[1].get_string()); | 150 | EXPECT_EQ("Fahrenheit", meta.settings_definitions()[1].get_dict()["displayValues"].get_array()[1].get_string()); |
2960 | 147 | ASSERT_EQ(4, meta.keywords().size()); | 151 | ASSERT_EQ(4u, meta.keywords().size()); |
2961 | 148 | EXPECT_NE(meta.keywords().end(), meta.keywords().find("music")); | 152 | EXPECT_NE(meta.keywords().end(), meta.keywords().find("music")); |
2962 | 149 | EXPECT_NE(meta.keywords().end(), meta.keywords().find("video")); | 153 | EXPECT_NE(meta.keywords().end(), meta.keywords().find("video")); |
2963 | 150 | EXPECT_NE(meta.keywords().end(), meta.keywords().find("news")); | 154 | EXPECT_NE(meta.keywords().end(), meta.keywords().find("news")); |
2964 | @@ -176,12 +180,12 @@ | |||
2965 | 176 | EXPECT_EQ("Dummy demo scope 3.", meta.description()); | 180 | EXPECT_EQ("Dummy demo scope 3.", meta.description()); |
2966 | 177 | EXPECT_EQ("Mr.Fake", meta.author()); | 181 | EXPECT_EQ("Mr.Fake", meta.author()); |
2967 | 178 | EXPECT_FALSE(meta.invisible()); | 182 | EXPECT_FALSE(meta.invisible()); |
2969 | 179 | EXPECT_EQ(4, meta.settings_definitions().size()); | 183 | EXPECT_EQ(4u, meta.settings_definitions().size()); |
2970 | 180 | EXPECT_EQ("unitTemp", meta.settings_definitions()[1].get_dict()["id"].get_string()); | 184 | EXPECT_EQ("unitTemp", meta.settings_definitions()[1].get_dict()["id"].get_string()); |
2971 | 181 | EXPECT_EQ("Temperature Units", meta.settings_definitions()[1].get_dict()["displayName"].get_string()); | 185 | EXPECT_EQ("Temperature Units", meta.settings_definitions()[1].get_dict()["displayName"].get_string()); |
2972 | 182 | EXPECT_EQ("list", meta.settings_definitions()[1].get_dict()["type"].get_string()); | 186 | EXPECT_EQ("list", meta.settings_definitions()[1].get_dict()["type"].get_string()); |
2973 | 183 | EXPECT_EQ(1, meta.settings_definitions()[1].get_dict()["defaultValue"].get_int()); | 187 | EXPECT_EQ(1, meta.settings_definitions()[1].get_dict()["defaultValue"].get_int()); |
2975 | 184 | EXPECT_EQ(2, meta.settings_definitions()[1].get_dict()["displayValues"].get_array().size()); | 188 | EXPECT_EQ(2u, meta.settings_definitions()[1].get_dict()["displayValues"].get_array().size()); |
2976 | 185 | EXPECT_EQ("Celsius", meta.settings_definitions()[1].get_dict()["displayValues"].get_array()[0].get_string()); | 189 | EXPECT_EQ("Celsius", meta.settings_definitions()[1].get_dict()["displayValues"].get_array()[0].get_string()); |
2977 | 186 | EXPECT_EQ("Fahrenheit", meta.settings_definitions()[1].get_dict()["displayValues"].get_array()[1].get_string()); | 190 | EXPECT_EQ("Fahrenheit", meta.settings_definitions()[1].get_dict()["displayValues"].get_array()[1].get_string()); |
2978 | 187 | } | 191 | } |
2979 | @@ -192,7 +196,7 @@ | |||
2980 | 192 | // set an invalid LANGUAGE env var (should return 0 scopes) | 196 | // set an invalid LANGUAGE env var (should return 0 scopes) |
2981 | 193 | ::setenv("LANGUAGE", "test_FAIL", 1); | 197 | ::setenv("LANGUAGE", "test_FAIL", 1); |
2982 | 194 | reset_reg(); | 198 | reset_reg(); |
2984 | 195 | EXPECT_EQ(0, reg_->list().size()); | 199 | EXPECT_EQ(0u, reg_->list().size()); |
2985 | 196 | 200 | ||
2986 | 197 | // set an empty LANGUAGE env var (should return 2 scopes) | 201 | // set an empty LANGUAGE env var (should return 2 scopes) |
2987 | 198 | ::setenv("LANGUAGE", "", 1); | 202 | ::setenv("LANGUAGE", "", 1); |
2988 | @@ -217,7 +221,7 @@ | |||
2989 | 217 | // set a colon seperated LANGUAGE env var (first invalid - should return 0 scopes) | 221 | // set a colon seperated LANGUAGE env var (first invalid - should return 0 scopes) |
2990 | 218 | ::setenv("LANGUAGE", "test_FAIL:test_TEST", 1); | 222 | ::setenv("LANGUAGE", "test_FAIL:test_TEST", 1); |
2991 | 219 | reset_reg(); | 223 | reset_reg(); |
2993 | 220 | EXPECT_EQ(0, reg_->list().size()); | 224 | EXPECT_EQ(0u, reg_->list().size()); |
2994 | 221 | } | 225 | } |
2995 | 222 | 226 | ||
2996 | 223 | class Receiver : public SearchListenerBase | 227 | class Receiver : public SearchListenerBase |
2997 | 224 | 228 | ||
2998 | === modified file 'test/gtest/scopes/internal/zmq_middleware/ConnectionPool/ConnectionPool_test.cpp' | |||
2999 | --- test/gtest/scopes/internal/zmq_middleware/ConnectionPool/ConnectionPool_test.cpp 2014-10-09 00:49:02 +0000 | |||
3000 | +++ test/gtest/scopes/internal/zmq_middleware/ConnectionPool/ConnectionPool_test.cpp 2017-01-16 06:43:13 +0000 | |||
3001 | @@ -20,7 +20,10 @@ | |||
3002 | 20 | 20 | ||
3003 | 21 | #include <zmqpp/context.hpp> | 21 | #include <zmqpp/context.hpp> |
3004 | 22 | 22 | ||
3005 | 23 | #pragma GCC diagnostic push | ||
3006 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3007 | 23 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
3008 | 26 | #pragma GCC diagnostic pop | ||
3009 | 24 | 27 | ||
3010 | 25 | using namespace std; | 28 | using namespace std; |
3011 | 26 | using namespace unity::scopes::internal::zmq_middleware; | 29 | using namespace unity::scopes::internal::zmq_middleware; |
3012 | 27 | 30 | ||
3013 | === modified file 'test/gtest/scopes/internal/zmq_middleware/ObjectAdapter/ObjectAdapter_test.cpp' | |||
3014 | --- test/gtest/scopes/internal/zmq_middleware/ObjectAdapter/ObjectAdapter_test.cpp 2014-11-18 07:04:04 +0000 | |||
3015 | +++ test/gtest/scopes/internal/zmq_middleware/ObjectAdapter/ObjectAdapter_test.cpp 2017-01-16 06:43:13 +0000 | |||
3016 | @@ -30,7 +30,11 @@ | |||
3017 | 30 | 30 | ||
3018 | 31 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. | 31 | #include <boost/regex.hpp> // Use Boost implementation until http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53631 is fixed. |
3019 | 32 | #include <capnp/serialize.h> | 32 | #include <capnp/serialize.h> |
3020 | 33 | |||
3021 | 34 | #pragma GCC diagnostic push | ||
3022 | 35 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3023 | 33 | #include <gtest/gtest.h> | 36 | #include <gtest/gtest.h> |
3024 | 37 | #pragma GCC diagnostic pop | ||
3025 | 34 | 38 | ||
3026 | 35 | using namespace std; | 39 | using namespace std; |
3027 | 36 | using namespace unity; | 40 | using namespace unity; |
3028 | 37 | 41 | ||
3029 | === modified file 'test/gtest/scopes/internal/zmq_middleware/PubSub/PubSub_test.cpp' | |||
3030 | --- test/gtest/scopes/internal/zmq_middleware/PubSub/PubSub_test.cpp 2014-11-18 07:04:04 +0000 | |||
3031 | +++ test/gtest/scopes/internal/zmq_middleware/PubSub/PubSub_test.cpp 2017-01-16 06:43:13 +0000 | |||
3032 | @@ -20,7 +20,11 @@ | |||
3033 | 20 | #include <unity/scopes/internal/zmq_middleware/ZmqMiddleware.h> | 20 | #include <unity/scopes/internal/zmq_middleware/ZmqMiddleware.h> |
3034 | 21 | #include <unity/scopes/ScopeExceptions.h> | 21 | #include <unity/scopes/ScopeExceptions.h> |
3035 | 22 | 22 | ||
3036 | 23 | #pragma GCC diagnostic push | ||
3037 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3038 | 23 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
3039 | 26 | #pragma GCC diagnostic pop | ||
3040 | 27 | |||
3041 | 24 | #include <condition_variable> | 28 | #include <condition_variable> |
3042 | 25 | #include <mutex> | 29 | #include <mutex> |
3043 | 26 | 30 | ||
3044 | 27 | 31 | ||
3045 | === modified file 'test/gtest/scopes/internal/zmq_middleware/RegistryI/RegistryI_test.cpp' | |||
3046 | --- test/gtest/scopes/internal/zmq_middleware/RegistryI/RegistryI_test.cpp 2016-02-22 00:19:46 +0000 | |||
3047 | +++ test/gtest/scopes/internal/zmq_middleware/RegistryI/RegistryI_test.cpp 2017-01-16 06:43:13 +0000 | |||
3048 | @@ -52,7 +52,10 @@ | |||
3049 | 52 | 52 | ||
3050 | 53 | #pragma pop_macro("BOOST_RANGE_ENABLE_CONCEPT_ASSERT") | 53 | #pragma pop_macro("BOOST_RANGE_ENABLE_CONCEPT_ASSERT") |
3051 | 54 | 54 | ||
3052 | 55 | #pragma GCC diagnostic push | ||
3053 | 56 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3054 | 55 | #include <gtest/gtest.h> | 57 | #include <gtest/gtest.h> |
3055 | 58 | #pragma GCC diagnostic pop | ||
3056 | 56 | 59 | ||
3057 | 57 | #include <array> | 60 | #include <array> |
3058 | 58 | #include <cassert> | 61 | #include <cassert> |
3059 | @@ -459,7 +462,7 @@ | |||
3060 | 459 | pid_t only_child_pid() | 462 | pid_t only_child_pid() |
3061 | 460 | { | 463 | { |
3062 | 461 | auto pids = child_pids(); | 464 | auto pids = child_pids(); |
3064 | 462 | EXPECT_EQ(1, pids.size()) << "Expected to find a single child process"; | 465 | EXPECT_EQ(1u, pids.size()) << "Expected to find a single child process"; |
3065 | 463 | return pids[0]; | 466 | return pids[0]; |
3066 | 464 | } | 467 | } |
3067 | 465 | 468 | ||
3068 | 466 | 469 | ||
3069 | === modified file 'test/gtest/scopes/internal/zmq_middleware/ServantBase/ServantBase_test.cpp' | |||
3070 | --- test/gtest/scopes/internal/zmq_middleware/ServantBase/ServantBase_test.cpp 2014-11-18 07:04:04 +0000 | |||
3071 | +++ test/gtest/scopes/internal/zmq_middleware/ServantBase/ServantBase_test.cpp 2017-01-16 06:43:13 +0000 | |||
3072 | @@ -22,7 +22,10 @@ | |||
3073 | 22 | #include <unity/scopes/internal/zmq_middleware/ObjectAdapter.h> | 22 | #include <unity/scopes/internal/zmq_middleware/ObjectAdapter.h> |
3074 | 23 | #include <unity/UnityExceptions.h> | 23 | #include <unity/UnityExceptions.h> |
3075 | 24 | 24 | ||
3076 | 25 | #pragma GCC diagnostic push | ||
3077 | 26 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3078 | 25 | #include <gtest/gtest.h> | 27 | #include <gtest/gtest.h> |
3079 | 28 | #pragma GCC diagnostic pop | ||
3080 | 26 | 29 | ||
3081 | 27 | #include <cassert> | 30 | #include <cassert> |
3082 | 28 | 31 | ||
3083 | 29 | 32 | ||
3084 | === modified file 'test/gtest/scopes/internal/zmq_middleware/StopPublisher/StopPublisher_test.cpp' | |||
3085 | --- test/gtest/scopes/internal/zmq_middleware/StopPublisher/StopPublisher_test.cpp 2014-04-14 23:47:33 +0000 | |||
3086 | +++ test/gtest/scopes/internal/zmq_middleware/StopPublisher/StopPublisher_test.cpp 2017-01-16 06:43:13 +0000 | |||
3087 | @@ -20,7 +20,10 @@ | |||
3088 | 20 | #include <unity/scopes/ScopeExceptions.h> | 20 | #include <unity/scopes/ScopeExceptions.h> |
3089 | 21 | #include <zmqpp/poller.hpp> | 21 | #include <zmqpp/poller.hpp> |
3090 | 22 | 22 | ||
3091 | 23 | #pragma GCC diagnostic push | ||
3092 | 24 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3093 | 23 | #include <gtest/gtest.h> | 25 | #include <gtest/gtest.h> |
3094 | 26 | #pragma GCC diagnostic pop | ||
3095 | 24 | 27 | ||
3096 | 25 | using namespace std; | 28 | using namespace std; |
3097 | 26 | using namespace unity::scopes; | 29 | using namespace unity::scopes; |
3098 | 27 | 30 | ||
3099 | === modified file 'test/gtest/scopes/internal/zmq_middleware/Util/Util_test.cpp' | |||
3100 | --- test/gtest/scopes/internal/zmq_middleware/Util/Util_test.cpp 2014-08-28 00:20:56 +0000 | |||
3101 | +++ test/gtest/scopes/internal/zmq_middleware/Util/Util_test.cpp 2017-01-16 06:43:13 +0000 | |||
3102 | @@ -22,7 +22,11 @@ | |||
3103 | 22 | #include <unity/scopes/ScopeExceptions.h> | 22 | #include <unity/scopes/ScopeExceptions.h> |
3104 | 23 | 23 | ||
3105 | 24 | #include <sys/un.h> | 24 | #include <sys/un.h> |
3106 | 25 | |||
3107 | 26 | #pragma GCC diagnostic push | ||
3108 | 27 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3109 | 25 | #include <gtest/gtest.h> | 28 | #include <gtest/gtest.h> |
3110 | 29 | #pragma GCC diagnostic pop | ||
3111 | 26 | 30 | ||
3112 | 27 | using namespace std; | 31 | using namespace std; |
3113 | 28 | using namespace unity; | 32 | using namespace unity; |
3114 | 29 | 33 | ||
3115 | === modified file 'test/gtest/scopes/internal/zmq_middleware/VariantConverter/VariantConverter_test.cpp' | |||
3116 | --- test/gtest/scopes/internal/zmq_middleware/VariantConverter/VariantConverter_test.cpp 2015-03-30 15:58:45 +0000 | |||
3117 | +++ test/gtest/scopes/internal/zmq_middleware/VariantConverter/VariantConverter_test.cpp 2017-01-16 06:43:13 +0000 | |||
3118 | @@ -20,8 +20,12 @@ | |||
3119 | 20 | #include <scopes/internal/zmq_middleware/capnproto/ValueDict.capnp.h> | 20 | #include <scopes/internal/zmq_middleware/capnproto/ValueDict.capnp.h> |
3120 | 21 | #include <unity/UnityExceptions.h> | 21 | #include <unity/UnityExceptions.h> |
3121 | 22 | 22 | ||
3122 | 23 | #include <capnp/message.h> | ||
3123 | 24 | |||
3124 | 25 | #pragma GCC diagnostic push | ||
3125 | 26 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3126 | 23 | #include <gtest/gtest.h> | 27 | #include <gtest/gtest.h> |
3128 | 24 | #include <capnp/message.h> | 28 | #pragma GCC diagnostic pop |
3129 | 25 | 29 | ||
3130 | 26 | using namespace std; | 30 | using namespace std; |
3131 | 27 | using namespace unity; | 31 | using namespace unity; |
3132 | 28 | 32 | ||
3133 | === modified file 'test/gtest/scopes/internal/zmq_middleware/ZmqMiddleware/ZmqMiddleware_test.cpp' | |||
3134 | --- test/gtest/scopes/internal/zmq_middleware/ZmqMiddleware/ZmqMiddleware_test.cpp 2015-05-29 12:02:54 +0000 | |||
3135 | +++ test/gtest/scopes/internal/zmq_middleware/ZmqMiddleware/ZmqMiddleware_test.cpp 2017-01-16 06:43:13 +0000 | |||
3136 | @@ -23,7 +23,10 @@ | |||
3137 | 23 | #include <unity/scopes/internal/zmq_middleware/ZmqObjectProxy.h> | 23 | #include <unity/scopes/internal/zmq_middleware/ZmqObjectProxy.h> |
3138 | 24 | #include <unity/scopes/ScopeExceptions.h> | 24 | #include <unity/scopes/ScopeExceptions.h> |
3139 | 25 | 25 | ||
3140 | 26 | #pragma GCC diagnostic push | ||
3141 | 27 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3142 | 26 | #include <gtest/gtest.h> | 28 | #include <gtest/gtest.h> |
3143 | 29 | #pragma GCC diagnostic pop | ||
3144 | 27 | 30 | ||
3145 | 28 | using namespace std; | 31 | using namespace std; |
3146 | 29 | using namespace unity::scopes; | 32 | using namespace unity::scopes; |
3147 | 30 | 33 | ||
3148 | === modified file 'test/gtest/scopes/qt/JsonAsyncReader/JsonAsyncReader_test.cpp' | |||
3149 | --- test/gtest/scopes/qt/JsonAsyncReader/JsonAsyncReader_test.cpp 2015-02-19 02:30:09 +0000 | |||
3150 | +++ test/gtest/scopes/qt/JsonAsyncReader/JsonAsyncReader_test.cpp 2017-01-16 06:43:13 +0000 | |||
3151 | @@ -23,7 +23,11 @@ | |||
3152 | 23 | 23 | ||
3153 | 24 | #include <QtCore/QJsonObject> | 24 | #include <QtCore/QJsonObject> |
3154 | 25 | 25 | ||
3155 | 26 | #pragma GCC diagnostic push | ||
3156 | 27 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3157 | 26 | #include <gtest/gtest.h> | 28 | #include <gtest/gtest.h> |
3158 | 29 | #pragma GCC diagnostic pop | ||
3159 | 30 | |||
3160 | 27 | #include <core/posix/exec.h> | 31 | #include <core/posix/exec.h> |
3161 | 28 | 32 | ||
3162 | 29 | namespace posix = core::posix; | 33 | namespace posix = core::posix; |
3163 | @@ -162,7 +166,7 @@ | |||
3164 | 162 | } | 166 | } |
3165 | 163 | 167 | ||
3166 | 164 | // check that we've got 5 valid results | 168 | // check that we've got 5 valid results |
3168 | 165 | EXPECT_EQ(results.size(), 5); | 169 | EXPECT_EQ(5u, results.size()); |
3169 | 166 | } | 170 | } |
3170 | 167 | 171 | ||
3171 | 168 | TEST_F(ExceptionsTest, check_xml_bad_formed) | 172 | TEST_F(ExceptionsTest, check_xml_bad_formed) |
3172 | 169 | 173 | ||
3173 | === modified file 'test/gtest/scopes/qt/XmlAsyncReader/XmlAsyncReader_test.cpp' | |||
3174 | --- test/gtest/scopes/qt/XmlAsyncReader/XmlAsyncReader_test.cpp 2015-02-19 02:30:09 +0000 | |||
3175 | +++ test/gtest/scopes/qt/XmlAsyncReader/XmlAsyncReader_test.cpp 2017-01-16 06:43:13 +0000 | |||
3176 | @@ -23,7 +23,10 @@ | |||
3177 | 23 | #include <QtCore/QXmlStreamReader> | 23 | #include <QtCore/QXmlStreamReader> |
3178 | 24 | #include <QtCore/QJsonObject> | 24 | #include <QtCore/QJsonObject> |
3179 | 25 | 25 | ||
3180 | 26 | #pragma GCC diagnostic push | ||
3181 | 27 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3182 | 26 | #include <gtest/gtest.h> | 28 | #include <gtest/gtest.h> |
3183 | 29 | #pragma GCC diagnostic pop | ||
3184 | 27 | 30 | ||
3185 | 28 | #include <core/posix/exec.h> | 31 | #include <core/posix/exec.h> |
3186 | 29 | 32 | ||
3187 | 30 | 33 | ||
3188 | === modified file 'test/gtest/scopes/qt/qt-bindings/QActionMetadata_test.cpp' | |||
3189 | --- test/gtest/scopes/qt/qt-bindings/QActionMetadata_test.cpp 2015-02-19 02:30:09 +0000 | |||
3190 | +++ test/gtest/scopes/qt/qt-bindings/QActionMetadata_test.cpp 2017-01-16 06:43:13 +0000 | |||
3191 | @@ -16,7 +16,10 @@ | |||
3192 | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> |
3193 | 17 | */ | 17 | */ |
3194 | 18 | 18 | ||
3195 | 19 | #pragma GCC diagnostic push | ||
3196 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3197 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
3198 | 22 | #pragma GCC diagnostic pop | ||
3199 | 20 | 23 | ||
3200 | 21 | #include <unity/scopes/qt/QActionMetadata.h> | 24 | #include <unity/scopes/qt/QActionMetadata.h> |
3201 | 22 | 25 | ||
3202 | 23 | 26 | ||
3203 | === modified file 'test/gtest/scopes/qt/qt-bindings/QCannedQuery_test.cpp' | |||
3204 | --- test/gtest/scopes/qt/qt-bindings/QCannedQuery_test.cpp 2015-02-24 02:11:17 +0000 | |||
3205 | +++ test/gtest/scopes/qt/qt-bindings/QCannedQuery_test.cpp 2017-01-16 06:43:13 +0000 | |||
3206 | @@ -16,7 +16,10 @@ | |||
3207 | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> |
3208 | 17 | */ | 17 | */ |
3209 | 18 | 18 | ||
3210 | 19 | #pragma GCC diagnostic push | ||
3211 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3212 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
3213 | 22 | #pragma GCC diagnostic pop | ||
3214 | 20 | 23 | ||
3215 | 21 | #include <unity/scopes/qt/QCannedQuery.h> | 24 | #include <unity/scopes/qt/QCannedQuery.h> |
3216 | 22 | #include <unity/scopes/qt/internal/QCannedQueryImpl.h> | 25 | #include <unity/scopes/qt/internal/QCannedQueryImpl.h> |
3217 | @@ -49,7 +52,7 @@ | |||
3218 | 49 | 52 | ||
3219 | 50 | unity::scopes::VariantMap api_map = api_query->serialize(); | 53 | unity::scopes::VariantMap api_map = api_query->serialize(); |
3220 | 51 | QVariantMap qt_map = query.serialize(); | 54 | QVariantMap qt_map = query.serialize(); |
3222 | 52 | EXPECT_EQ(api_map.size(), qt_map.size()); | 55 | EXPECT_EQ(int(api_map.size()), qt_map.size()); |
3223 | 53 | EXPECT_TRUE(qt_map.size() != 0); | 56 | EXPECT_TRUE(qt_map.size() != 0); |
3224 | 54 | EXPECT_EQ(variantmap_to_qvariantmap(api_map), qt_map); | 57 | EXPECT_EQ(variantmap_to_qvariantmap(api_map), qt_map); |
3225 | 55 | 58 | ||
3226 | 56 | 59 | ||
3227 | === modified file 'test/gtest/scopes/qt/qt-bindings/QCategorisedResult_test.cpp' | |||
3228 | --- test/gtest/scopes/qt/qt-bindings/QCategorisedResult_test.cpp 2015-02-25 12:37:03 +0000 | |||
3229 | +++ test/gtest/scopes/qt/qt-bindings/QCategorisedResult_test.cpp 2017-01-16 06:43:13 +0000 | |||
3230 | @@ -16,7 +16,10 @@ | |||
3231 | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> |
3232 | 17 | */ | 17 | */ |
3233 | 18 | 18 | ||
3234 | 19 | #pragma GCC diagnostic push | ||
3235 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3236 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
3237 | 22 | #pragma GCC diagnostic pop | ||
3238 | 20 | 23 | ||
3239 | 21 | #include <unity/scopes/qt/QCategorisedResult.h> | 24 | #include <unity/scopes/qt/QCategorisedResult.h> |
3240 | 22 | #include <unity/scopes/qt/QCategory.h> | 25 | #include <unity/scopes/qt/QCategory.h> |
3241 | 23 | 26 | ||
3242 | === modified file 'test/gtest/scopes/qt/qt-bindings/QColumnLayout_test.cpp' | |||
3243 | --- test/gtest/scopes/qt/qt-bindings/QColumnLayout_test.cpp 2015-02-24 02:11:17 +0000 | |||
3244 | +++ test/gtest/scopes/qt/qt-bindings/QColumnLayout_test.cpp 2017-01-16 06:43:13 +0000 | |||
3245 | @@ -16,7 +16,10 @@ | |||
3246 | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> |
3247 | 17 | */ | 17 | */ |
3248 | 18 | 18 | ||
3249 | 19 | #pragma GCC diagnostic push | ||
3250 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3251 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
3252 | 22 | #pragma GCC diagnostic pop | ||
3253 | 20 | 23 | ||
3254 | 21 | #include <unity/scopes/qt/QColumnLayout.h> | 24 | #include <unity/scopes/qt/QColumnLayout.h> |
3255 | 22 | #include <unity/scopes/qt/internal/QColumnLayoutImpl.h> | 25 | #include <unity/scopes/qt/internal/QColumnLayoutImpl.h> |
3256 | @@ -50,7 +53,7 @@ | |||
3257 | 50 | QVector<QString> retrieved_widget_ids = layout.column(0); | 53 | QVector<QString> retrieved_widget_ids = layout.column(0); |
3258 | 51 | 54 | ||
3259 | 52 | std::vector<std::string> api_widgets = api_layout->column(0); | 55 | std::vector<std::string> api_widgets = api_layout->column(0); |
3261 | 53 | EXPECT_EQ(api_widgets.size(), retrieved_widget_ids.size()); | 56 | EXPECT_EQ(int(api_widgets.size()), retrieved_widget_ids.size()); |
3262 | 54 | EXPECT_TRUE(api_widgets.size() != 0); | 57 | EXPECT_TRUE(api_widgets.size() != 0); |
3263 | 55 | for (uint i = 0; i < api_widgets.size(); ++i) | 58 | for (uint i = 0; i < api_widgets.size(); ++i) |
3264 | 56 | { | 59 | { |
3265 | @@ -59,7 +62,7 @@ | |||
3266 | 59 | 62 | ||
3267 | 60 | retrieved_widget_ids = layout.column(1); | 63 | retrieved_widget_ids = layout.column(1); |
3268 | 61 | api_widgets = api_layout->column(1); | 64 | api_widgets = api_layout->column(1); |
3270 | 62 | EXPECT_EQ(api_widgets.size(), retrieved_widget_ids.size()); | 65 | EXPECT_EQ(int(api_widgets.size()), retrieved_widget_ids.size()); |
3271 | 63 | EXPECT_TRUE(api_widgets.size() != 0); | 66 | EXPECT_TRUE(api_widgets.size() != 0); |
3272 | 64 | for (uint i = 0; i < api_widgets.size(); ++i) | 67 | for (uint i = 0; i < api_widgets.size(); ++i) |
3273 | 65 | { | 68 | { |
3274 | 66 | 69 | ||
3275 | === modified file 'test/gtest/scopes/qt/qt-bindings/QDepartment_test.cpp' | |||
3276 | --- test/gtest/scopes/qt/qt-bindings/QDepartment_test.cpp 2015-02-24 02:11:17 +0000 | |||
3277 | +++ test/gtest/scopes/qt/qt-bindings/QDepartment_test.cpp 2017-01-16 06:43:13 +0000 | |||
3278 | @@ -16,7 +16,10 @@ | |||
3279 | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> |
3280 | 17 | */ | 17 | */ |
3281 | 18 | 18 | ||
3282 | 19 | #pragma GCC diagnostic push | ||
3283 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3284 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
3285 | 22 | #pragma GCC diagnostic pop | ||
3286 | 20 | 23 | ||
3287 | 21 | #include <unity/scopes/qt/QCannedQuery.h> | 24 | #include <unity/scopes/qt/QCannedQuery.h> |
3288 | 22 | #include <unity/scopes/qt/QDepartment.h> | 25 | #include <unity/scopes/qt/QDepartment.h> |
3289 | @@ -63,7 +66,7 @@ | |||
3290 | 63 | unity::scopes::DepartmentList api_list = api_dep->subdepartments(); | 66 | unity::scopes::DepartmentList api_list = api_dep->subdepartments(); |
3291 | 64 | 67 | ||
3292 | 65 | EXPECT_TRUE(qt_list.size() != 0); | 68 | EXPECT_TRUE(qt_list.size() != 0); |
3294 | 66 | EXPECT_EQ(qt_list.size(), api_list.size()); | 69 | EXPECT_EQ(qt_list.size(), int(api_list.size())); |
3295 | 67 | 70 | ||
3296 | 68 | std::vector<std::string> dep_ids; | 71 | std::vector<std::string> dep_ids; |
3297 | 69 | for (auto item : api_list) | 72 | for (auto item : api_list) |
3298 | 70 | 73 | ||
3299 | === modified file 'test/gtest/scopes/qt/qt-bindings/QPreviewQueryBaseAPI_test.cpp' | |||
3300 | --- test/gtest/scopes/qt/qt-bindings/QPreviewQueryBaseAPI_test.cpp 2015-02-19 05:27:04 +0000 | |||
3301 | +++ test/gtest/scopes/qt/qt-bindings/QPreviewQueryBaseAPI_test.cpp 2017-01-16 06:43:13 +0000 | |||
3302 | @@ -16,8 +16,10 @@ | |||
3303 | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> |
3304 | 17 | */ | 17 | */ |
3305 | 18 | 18 | ||
3307 | 19 | #include <gtest/gtest.h> | 19 | #pragma GCC diagnostic push |
3308 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3309 | 20 | #include <gmock/gmock.h> | 21 | #include <gmock/gmock.h> |
3310 | 22 | #pragma GCC diagnostic pop | ||
3311 | 21 | 23 | ||
3312 | 22 | #include "BasicEventsChecker.h" | 24 | #include "BasicEventsChecker.h" |
3313 | 23 | #include "TestSetup.h" | 25 | #include "TestSetup.h" |
3314 | 24 | 26 | ||
3315 | === modified file 'test/gtest/scopes/qt/qt-bindings/QPreviewWidget_test.cpp' | |||
3316 | --- test/gtest/scopes/qt/qt-bindings/QPreviewWidget_test.cpp 2015-02-24 06:56:42 +0000 | |||
3317 | +++ test/gtest/scopes/qt/qt-bindings/QPreviewWidget_test.cpp 2017-01-16 06:43:13 +0000 | |||
3318 | @@ -16,7 +16,10 @@ | |||
3319 | 16 | * Authored by: Michi Henning <michi.henning@canonical.com> | 16 | * Authored by: Michi Henning <michi.henning@canonical.com> |
3320 | 17 | */ | 17 | */ |
3321 | 18 | 18 | ||
3322 | 19 | #pragma GCC diagnostic push | ||
3323 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3324 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
3325 | 22 | #pragma GCC diagnostic pop | ||
3326 | 20 | 23 | ||
3327 | 21 | #include <unity/scopes/qt/QPreviewWidget.h> | 24 | #include <unity/scopes/qt/QPreviewWidget.h> |
3328 | 22 | #include <unity/scopes/qt/internal/QPreviewWidgetImpl.h> | 25 | #include <unity/scopes/qt/internal/QPreviewWidgetImpl.h> |
3329 | 23 | 26 | ||
3330 | === modified file 'test/gtest/scopes/qt/qt-bindings/QScopeBaseAPIImpl_test.cpp' | |||
3331 | --- test/gtest/scopes/qt/qt-bindings/QScopeBaseAPIImpl_test.cpp 2015-02-24 04:03:22 +0000 | |||
3332 | +++ test/gtest/scopes/qt/qt-bindings/QScopeBaseAPIImpl_test.cpp 2017-01-16 06:43:13 +0000 | |||
3333 | @@ -16,9 +16,11 @@ | |||
3334 | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> |
3335 | 17 | */ | 17 | */ |
3336 | 18 | 18 | ||
3338 | 19 | #include <gtest/gtest.h> | 19 | #pragma GCC diagnostic push |
3339 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3340 | 20 | #include <gmock/gmock.h> | 21 | #include <gmock/gmock.h> |
3341 | 21 | #include <gmock/gmock-actions.h> | 22 | #include <gmock/gmock-actions.h> |
3342 | 23 | #pragma GCC diagnostic pop | ||
3343 | 22 | 24 | ||
3344 | 23 | #include "QMockScope.h" | 25 | #include "QMockScope.h" |
3345 | 24 | #include "QScopeBaseAPIMock.h" | 26 | #include "QScopeBaseAPIMock.h" |
3346 | 25 | 27 | ||
3347 | === modified file 'test/gtest/scopes/qt/qt-bindings/QScopeCreation_test.cpp' | |||
3348 | --- test/gtest/scopes/qt/qt-bindings/QScopeCreation_test.cpp 2015-02-24 04:05:51 +0000 | |||
3349 | +++ test/gtest/scopes/qt/qt-bindings/QScopeCreation_test.cpp 2017-01-16 06:43:13 +0000 | |||
3350 | @@ -17,7 +17,11 @@ | |||
3351 | 17 | */ | 17 | */ |
3352 | 18 | 18 | ||
3353 | 19 | #include "FakeScope.h" | 19 | #include "FakeScope.h" |
3354 | 20 | |||
3355 | 21 | #pragma GCC diagnostic push | ||
3356 | 22 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3357 | 20 | #include <gtest/gtest.h> | 23 | #include <gtest/gtest.h> |
3358 | 24 | #pragma GCC diagnostic pop | ||
3359 | 21 | 25 | ||
3360 | 22 | #include <unity/scopes/qt/QScopeBaseAPI.h> | 26 | #include <unity/scopes/qt/QScopeBaseAPI.h> |
3361 | 23 | 27 | ||
3362 | 24 | 28 | ||
3363 | === modified file 'test/gtest/scopes/qt/qt-bindings/QSearchMetadata_test.cpp' | |||
3364 | --- test/gtest/scopes/qt/qt-bindings/QSearchMetadata_test.cpp 2015-02-19 02:30:09 +0000 | |||
3365 | +++ test/gtest/scopes/qt/qt-bindings/QSearchMetadata_test.cpp 2017-01-16 06:43:13 +0000 | |||
3366 | @@ -16,7 +16,10 @@ | |||
3367 | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> |
3368 | 17 | */ | 17 | */ |
3369 | 18 | 18 | ||
3370 | 19 | #pragma GCC diagnostic push | ||
3371 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3372 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
3373 | 22 | #pragma GCC diagnostic pop | ||
3374 | 20 | 23 | ||
3375 | 21 | #include <unity/scopes/qt/QSearchMetadata.h> | 24 | #include <unity/scopes/qt/QSearchMetadata.h> |
3376 | 22 | 25 | ||
3377 | 23 | 26 | ||
3378 | === modified file 'test/gtest/scopes/qt/qt-bindings/QSearchQueryBaseAPI_test.cpp' | |||
3379 | --- test/gtest/scopes/qt/qt-bindings/QSearchQueryBaseAPI_test.cpp 2015-02-19 02:30:09 +0000 | |||
3380 | +++ test/gtest/scopes/qt/qt-bindings/QSearchQueryBaseAPI_test.cpp 2017-01-16 06:43:13 +0000 | |||
3381 | @@ -16,8 +16,10 @@ | |||
3382 | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> |
3383 | 17 | */ | 17 | */ |
3384 | 18 | 18 | ||
3386 | 19 | #include <gtest/gtest.h> | 19 | #pragma GCC diagnostic push |
3387 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3388 | 20 | #include <gmock/gmock.h> | 21 | #include <gmock/gmock.h> |
3389 | 22 | #pragma GCC diagnostic pop | ||
3390 | 21 | 23 | ||
3391 | 22 | #include "BasicEventsChecker.h" | 24 | #include "BasicEventsChecker.h" |
3392 | 23 | #include "TestSetup.h" | 25 | #include "TestSetup.h" |
3393 | 24 | 26 | ||
3394 | === modified file 'test/gtest/scopes/qt/qt-bindings/QUtils_test.cpp' | |||
3395 | --- test/gtest/scopes/qt/qt-bindings/QUtils_test.cpp 2015-02-24 02:11:17 +0000 | |||
3396 | +++ test/gtest/scopes/qt/qt-bindings/QUtils_test.cpp 2017-01-16 06:43:13 +0000 | |||
3397 | @@ -16,7 +16,10 @@ | |||
3398 | 16 | * Authored by: Michi Henning <michi.henning@canonical.com> | 16 | * Authored by: Michi Henning <michi.henning@canonical.com> |
3399 | 17 | */ | 17 | */ |
3400 | 18 | 18 | ||
3401 | 19 | #pragma GCC diagnostic push | ||
3402 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3403 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
3404 | 22 | #pragma GCC diagnostic pop | ||
3405 | 20 | 23 | ||
3406 | 21 | #include <unity/scopes/qt/internal/QUtils.h> | 24 | #include <unity/scopes/qt/internal/QUtils.h> |
3407 | 22 | 25 | ||
3408 | @@ -161,7 +164,7 @@ | |||
3409 | 161 | qvm["string"] = "Hello"; | 164 | qvm["string"] = "Hello"; |
3410 | 162 | 165 | ||
3411 | 163 | VariantMap vm = qvariantmap_to_variantmap(qvm); | 166 | VariantMap vm = qvariantmap_to_variantmap(qvm); |
3413 | 164 | ASSERT_EQ(2, vm.size()); | 167 | ASSERT_EQ(2u, vm.size()); |
3414 | 165 | EXPECT_EQ(42, vm["int"].get_int()); | 168 | EXPECT_EQ(42, vm["int"].get_int()); |
3415 | 166 | EXPECT_EQ("Hello", vm["string"].get_string()); | 169 | EXPECT_EQ("Hello", vm["string"].get_string()); |
3416 | 167 | } | 170 | } |
3417 | 168 | 171 | ||
3418 | === modified file 'test/gtest/scopes/qt/qt-bindings/QVariantBuilder_test.cpp' | |||
3419 | --- test/gtest/scopes/qt/qt-bindings/QVariantBuilder_test.cpp 2015-02-24 02:11:17 +0000 | |||
3420 | +++ test/gtest/scopes/qt/qt-bindings/QVariantBuilder_test.cpp 2017-01-16 06:43:13 +0000 | |||
3421 | @@ -16,7 +16,10 @@ | |||
3422 | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> | 16 | * Authored by: Xavi Garcia <xavi.garcia.mena@canonical.com> |
3423 | 17 | */ | 17 | */ |
3424 | 18 | 18 | ||
3425 | 19 | #pragma GCC diagnostic push | ||
3426 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3427 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
3428 | 22 | #pragma GCC diagnostic pop | ||
3429 | 20 | 23 | ||
3430 | 21 | #include <unity/scopes/qt/QVariantBuilder.h> | 24 | #include <unity/scopes/qt/QVariantBuilder.h> |
3431 | 22 | #include <unity/scopes/qt/internal/QVariantBuilderImpl.h> | 25 | #include <unity/scopes/qt/internal/QVariantBuilderImpl.h> |
3432 | 23 | 26 | ||
3433 | === modified file 'test/gtest/scopes/stress/scopes-stress.cpp' | |||
3434 | --- test/gtest/scopes/stress/scopes-stress.cpp 2014-10-24 17:59:48 +0000 | |||
3435 | +++ test/gtest/scopes/stress/scopes-stress.cpp 2017-01-16 06:43:13 +0000 | |||
3436 | @@ -18,7 +18,11 @@ | |||
3437 | 18 | 18 | ||
3438 | 19 | // You may also include individual headers if you prefer. | 19 | // You may also include individual headers if you prefer. |
3439 | 20 | #include <unity-scopes.h> | 20 | #include <unity-scopes.h> |
3440 | 21 | |||
3441 | 22 | #pragma GCC diagnostic push | ||
3442 | 23 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3443 | 21 | #include <gtest/gtest.h> | 24 | #include <gtest/gtest.h> |
3444 | 25 | #pragma GCC diagnostic pop | ||
3445 | 22 | 26 | ||
3446 | 23 | #include <boost/filesystem.hpp> | 27 | #include <boost/filesystem.hpp> |
3447 | 24 | #include <condition_variable> | 28 | #include <condition_variable> |
3448 | @@ -107,7 +111,7 @@ | |||
3449 | 107 | RegistryProxy r = rt->registry(); | 111 | RegistryProxy r = rt->registry(); |
3450 | 108 | 112 | ||
3451 | 109 | auto scopes_meta = r->list(); | 113 | auto scopes_meta = r->list(); |
3453 | 110 | EXPECT_EQ(scopes_meta.size(), 3); | 114 | EXPECT_EQ(3u, scopes_meta.size()); |
3454 | 111 | 115 | ||
3455 | 112 | const std::list<std::string> scopes {"scope1", "scope2", "scope3"}; | 116 | const std::list<std::string> scopes {"scope1", "scope2", "scope3"}; |
3456 | 113 | 117 | ||
3457 | @@ -131,7 +135,7 @@ | |||
3458 | 131 | { | 135 | { |
3459 | 132 | reply->wait_until_finished(); | 136 | reply->wait_until_finished(); |
3460 | 133 | cout << "finished query for scope " << reply->scope_id() << endl; | 137 | cout << "finished query for scope " << reply->scope_id() << endl; |
3462 | 134 | EXPECT_EQ(reply->result_count(), 20u); | 138 | EXPECT_EQ(20, reply->result_count()); |
3463 | 135 | } | 139 | } |
3464 | 136 | } | 140 | } |
3465 | 137 | } | 141 | } |
3466 | 138 | 142 | ||
3467 | === modified file 'test/gtest/scopes/testing/IsolatedScope/IsolatedScope_test.cpp' | |||
3468 | --- test/gtest/scopes/testing/IsolatedScope/IsolatedScope_test.cpp 2015-01-28 09:03:59 +0000 | |||
3469 | +++ test/gtest/scopes/testing/IsolatedScope/IsolatedScope_test.cpp 2017-01-16 06:43:13 +0000 | |||
3470 | @@ -32,7 +32,10 @@ | |||
3471 | 32 | 32 | ||
3472 | 33 | #include <unity/scopes/CategoryRenderer.h> | 33 | #include <unity/scopes/CategoryRenderer.h> |
3473 | 34 | 34 | ||
3474 | 35 | #pragma GCC diagnostic push | ||
3475 | 36 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3476 | 35 | #include <gtest/gtest.h> | 37 | #include <gtest/gtest.h> |
3477 | 38 | #pragma GCC diagnostic pop | ||
3478 | 36 | 39 | ||
3479 | 37 | #include "scope.h" | 40 | #include "scope.h" |
3480 | 38 | 41 | ||
3481 | 39 | 42 | ||
3482 | === modified file 'test/gtest/scopes/testing/IsolatedScopeBenchmark/IsolatedScopeBenchmark_test.cpp' | |||
3483 | --- test/gtest/scopes/testing/IsolatedScopeBenchmark/IsolatedScopeBenchmark_test.cpp 2014-08-01 14:31:16 +0000 | |||
3484 | +++ test/gtest/scopes/testing/IsolatedScopeBenchmark/IsolatedScopeBenchmark_test.cpp 2017-01-16 06:43:13 +0000 | |||
3485 | @@ -26,7 +26,10 @@ | |||
3486 | 26 | 26 | ||
3487 | 27 | #include <unity/scopes/CategoryRenderer.h> | 27 | #include <unity/scopes/CategoryRenderer.h> |
3488 | 28 | 28 | ||
3489 | 29 | #pragma GCC diagnostic push | ||
3490 | 30 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3491 | 29 | #include <gtest/gtest.h> | 31 | #include <gtest/gtest.h> |
3492 | 32 | #pragma GCC diagnostic pop | ||
3493 | 30 | 33 | ||
3494 | 31 | #include "config.h" | 34 | #include "config.h" |
3495 | 32 | #include "scope.h" | 35 | #include "scope.h" |
3496 | 33 | 36 | ||
3497 | === modified file 'test/gtest/scopes/testing/Statistics/Statistics_test.cpp' | |||
3498 | --- test/gtest/scopes/testing/Statistics/Statistics_test.cpp 2014-08-28 00:20:56 +0000 | |||
3499 | +++ test/gtest/scopes/testing/Statistics/Statistics_test.cpp 2017-01-16 06:43:13 +0000 | |||
3500 | @@ -19,7 +19,10 @@ | |||
3501 | 19 | #include <unity/scopes/testing/Benchmark.h> | 19 | #include <unity/scopes/testing/Benchmark.h> |
3502 | 20 | #include <unity/scopes/testing/Statistics.h> | 20 | #include <unity/scopes/testing/Statistics.h> |
3503 | 21 | 21 | ||
3504 | 22 | #pragma GCC diagnostic push | ||
3505 | 23 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3506 | 22 | #include <gtest/gtest.h> | 24 | #include <gtest/gtest.h> |
3507 | 25 | #pragma GCC diagnostic pop | ||
3508 | 23 | 26 | ||
3509 | 24 | #include "config.h" | 27 | #include "config.h" |
3510 | 25 | 28 | ||
3511 | 26 | 29 | ||
3512 | === modified file 'test/gtest/scopes/utility/BufferedResultForwarder/BufferedResultForwarder_test.cpp' | |||
3513 | --- test/gtest/scopes/utility/BufferedResultForwarder/BufferedResultForwarder_test.cpp 2014-12-01 01:51:38 +0000 | |||
3514 | +++ test/gtest/scopes/utility/BufferedResultForwarder/BufferedResultForwarder_test.cpp 2017-01-16 06:43:13 +0000 | |||
3515 | @@ -16,7 +16,11 @@ | |||
3516 | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> | 16 | * Authored by: Pawel Stolowski <pawel.stolowski@canonical.com> |
3517 | 17 | */ | 17 | */ |
3518 | 18 | 18 | ||
3519 | 19 | #pragma GCC diagnostic push | ||
3520 | 20 | #pragma GCC diagnostic ignored "-Wctor-dtor-privacy" | ||
3521 | 19 | #include <gtest/gtest.h> | 21 | #include <gtest/gtest.h> |
3522 | 22 | #pragma GCC diagnostic pop | ||
3523 | 23 | |||
3524 | 20 | #include <unity/scopes/utility/BufferedResultForwarder.h> | 24 | #include <unity/scopes/utility/BufferedResultForwarder.h> |
3525 | 21 | #include <unity/scopes/CategoryRenderer.h> | 25 | #include <unity/scopes/CategoryRenderer.h> |
3526 | 22 | #include <unity/scopes/testing/MockSearchReply.h> | 26 | #include <unity/scopes/testing/MockSearchReply.h> |
Looks good.