adamdebreceni commented on code in PR #1930:
URL: https://github.com/apache/nifi-minifi-cpp/pull/1930#discussion_r2213254021


##########
libminifi/test/unit/ProcessorConfigUtilsTests.cpp:
##########
@@ -46,8 +53,11 @@ TEST_CASE("Parse enum property") {
   static constexpr auto prop = 
PropertyDefinitionBuilder<magic_enum::enum_count<TestEnum>()>::createProperty("prop")
       .withAllowedValues(magic_enum::enum_names<TestEnum>())
       .build();
-  auto proc = std::make_shared<TestProcessor>("test-proc");
-  proc->setSupportedProperties(std::to_array<core::PropertyReference>({prop}));
+  auto proc = minifi::test::utils::make_processor<TestProcessor>("test-proc");
+  proc->getImpl<TestProcessor>().on_initialize_ = [&] (auto& self) {
+    
self.setSupportedProperties(std::to_array<core::PropertyReference>({prop}));
+  };
+  proc->initialize();

Review Comment:
   `Processor::setSupportedProperties` will become is kind of unnecessary going 
forward, and should only be called by the implementation during initialize 
(indirectly on self), a number of member should be made 
protected/private/removed on both Processor and ProcessorImpl in upcoming PRs



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to