zhztheplayer commented on code in PR #11006:
URL: 
https://github.com/apache/incubator-gluten/pull/11006#discussion_r2486059910


##########
gluten-core/src/test/scala/org/apache/gluten/component/ComponentSuite.scala:
##########
@@ -49,53 +55,53 @@ class ComponentSuite extends AnyFunSuite with 
BeforeAndAfterAll {
   }
 
   test("Register again") {
+    class DummyBackendA extends DummyBackend("A")
+    new DummyBackendA().ensureRegistered()
     assertThrows[IllegalArgumentException] {
       new DummyBackendA().ensureRegistered()
     }
   }
-}
 
-object ComponentSuite {
-  private class DummyBackendA extends Backend {
-    override def name(): String = "dummy-backend-a"
-    override def buildInfo(): Component.BuildInfo =
-      Component.BuildInfo("DUMMY_BACKEND_A", "N/A", "N/A", "N/A")
-    override def injectRules(injector: Injector): Unit = {}
-  }
+  test("Dependencies not registered") {

Review Comment:
   @PHILO-HE, this test case shows an error is thrown when we only exclude a 
component, but still register its dependents at runtime.
   
   Moving forward we'd exclude all dependents as well when a component is 
excluded.
   
   This is not really a corner case but something practical - for example, if 
`VeloxDeltaComponent` is excluded, `VeloxDelta33WriteComponent` has to be 
excluded as well. Otherwise, an exception will be thrown during component 
registration.



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to