szaszm commented on a change in pull request #1252:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1252#discussion_r798799427



##########
File path: extensions/aws/processors/ListS3.h
##########
@@ -33,6 +33,7 @@ namespace org {
 namespace apache {
 namespace nifi {
 namespace minifi {
+

Review comment:
       Please remove this unnecessary new line

##########
File path: extensions/http-curl/tests/C2NullConfiguration.cpp
##########
@@ -61,10 +61,10 @@ class VerifyC2Server : public HTTPIntegrationBase {
   }
 
   void queryRootProcessGroup(std::shared_ptr<core::ProcessGroup> pg) override {
-    std::shared_ptr<core::Processor> proc = pg->findProcessorByName("invoke");
+    auto* const proc = pg->findProcessorByName("invoke");
     assert(proc != nullptr);
 
-    std::shared_ptr<minifi::processors::InvokeHTTP> inv = 
std::dynamic_pointer_cast<minifi::processors::InvokeHTTP>(proc);
+    const auto inv = dynamic_cast<minifi::processors::InvokeHTTP*>(proc);

Review comment:
       Use `auto* const` here as well. Consider adding const to the pointer as 
well, since it's only read from in these functions.

##########
File path: extensions/coap/tests/CoapC2VerifyHeartbeat.cpp
##########
@@ -92,10 +92,10 @@ class VerifyCoAPServer : public CoapIntegrationBase {
   }
 
   void queryRootProcessGroup(std::shared_ptr<core::ProcessGroup> pg) override {
-    std::shared_ptr<core::Processor> proc = pg->findProcessorByName("invoke");
+    auto proc = pg->findProcessorByName("invoke");

Review comment:
       Use `auto* const` here as well

##########
File path: CMakeLists.txt
##########
@@ -611,6 +612,11 @@ if (ENABLE_KUBERNETES)
   createExtension(KUBERNETES-EXTENSIONS "KUBERNETES EXTENSIONS" "This enables 
Kubernetes support" "extensions/kubernetes")
 endif()
 
+## Add the test-processors extension
+if (ENABLE_ALL OR NOT SKIP_TESTS OR ENABLE_TEST_PROCESSORS)
+       createExtension(TEST-PROCESSORS-EXTENSION "TEST-PROCESSORS EXTENSION" 
"This enables processors purely for testing purposes" 
"extensions/test-processors")
+endif()

Review comment:
       I would run them when `NOT SKIP_TESTS`, regardless of the other options, 
since it's basically testing.

##########
File path: extensions/coap/tests/CoapC2VerifyHeartbeat.cpp
##########
@@ -92,10 +92,10 @@ class VerifyCoAPServer : public CoapIntegrationBase {
   }
 
   void queryRootProcessGroup(std::shared_ptr<core::ProcessGroup> pg) override {
-    std::shared_ptr<core::Processor> proc = pg->findProcessorByName("invoke");
+    auto proc = pg->findProcessorByName("invoke");
     assert(proc != nullptr);
 
-    std::shared_ptr<minifi::processors::InvokeHTTP> inv = 
std::dynamic_pointer_cast<minifi::processors::InvokeHTTP>(proc);
+    auto inv = dynamic_cast<minifi::processors::InvokeHTTP*>(proc);

Review comment:
       Use `auto* const` here as well. Consider adding const to the pointer as 
well, since it's only read from in these functions.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@nifi.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to