File tree Expand file tree Collapse file tree 4 files changed +3
-46
lines changed Expand file tree Collapse file tree 4 files changed +3
-46
lines changed Original file line number Diff line number Diff line change @@ -9,7 +9,6 @@ set(CMAKE_CXX_STANDARD 11)
99add_library (${project_name} -lib
1010 src/App.cpp
1111 src/AppComponent.hpp
12- src/Logger.hpp
1312 src/ServiceComponent.hpp
1413 src/SwaggerComponent.hpp
1514 src/controller/UserController.cpp
Original file line number Diff line number Diff line change 1010#include " ./AppComponent.hpp"
1111#include " ./ServiceComponent.hpp"
1212#include " ./SwaggerComponent.hpp"
13- #include " ./Logger.hpp"
1413
1514#include " oatpp/network/server/Server.hpp"
1615
@@ -59,14 +58,11 @@ void run(const oatpp::base::CommandLineArguments& args) {
5958 * main
6059 */
6160int main (int argc, const char * argv[]) {
62-
63- oatpp::base::Environment::setLogger (new Logger ());
61+
6462 oatpp::base::Environment::init ();
6563
6664 run (oatpp::base::CommandLineArguments (argc, argv));
6765
68- oatpp::base::Environment::setLogger (nullptr ); // /< free Logger
69-
7066 /* Print how much objects were created during app running, and what have left-probably leaked */
7167 /* Disable object counting for release builds using '-D OATPP_DISABLE_ENV_OBJECT_COUNTERS' flag for better performance */
7268 std::cout << " \n Environment:\n " ;
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 11
2- #include " Logger.hpp"
3-
42#include " oatpp-test/UnitTest.hpp"
53#include < iostream>
64
@@ -26,13 +24,9 @@ void runTests() {
2624int main () {
2725
2826 oatpp::base::Environment::init ();
29- oatpp::base::Environment::setLogger (new Logger ());
3027
3128 runTests ();
3229
33- oatpp::base::Environment::setLogger (nullptr );
34- oatpp::base::Environment::destroy ();
35-
3630 /* Print how much objects were created during app running, and what have left-probably leaked */
3731 /* Disable object counting for release builds using '-D OATPP_DISABLE_ENV_OBJECT_COUNTERS' flag for better performance */
3832 std::cout << " \n Environment:\n " ;
@@ -41,5 +35,7 @@ int main() {
4135
4236 OATPP_ASSERT (oatpp::base::Environment::getObjectsCount () == 0 );
4337
38+ oatpp::base::Environment::destroy ();
39+
4440 return 0 ;
4541}
You can’t perform that action at this time.
0 commit comments