lhotari opened a new issue, #21754:
URL: https://github.com/apache/pulsar/issues/21754

   ### Search before asking
   
   - [X] I searched in the [issues](https://github.com/apache/pulsar/issues) 
and found nothing similar.
   
   ### Example failures
   
   - 
[2023-12-19T06:32:08.7068620Z](https://github.com/apache/pulsar/actions/runs/7257984423/job/19772827749#step:11:1117)
 
   
   
   ### Exception stacktrace
   
   ```
   org.mockito.exceptions.misusing.WrongTypeOfReturnValue:
   
   NamespaceService cannot be returned by getPulsarResources()
   getPulsarResources() should return PulsarResources
   ***
   If you're unsure why you're getting above error read on.
   Due to the nature of the syntax above problem might occur because:
   1. This exception *might* occur in wrongly written multi-threaded tests.
      Please refer to Mockito FAQ on limitations of concurrency testing.
   2. A spy is stubbed using when(spy.foo()).then() syntax. It is safer to stub 
spies -
      - with doReturn|Throw() family of methods. More in javadocs for 
Mockito.spy() method.
   
        at 
org.apache.pulsar.broker.PulsarService.getNamespaceService(PulsarService.java:1350)
        at 
org.apache.pulsar.broker.service.PersistentTopicTest.setup(PersistentTopicTest.java:217)
        at 
java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
        at java.base/java.lang.reflect.Method.invoke(Method.java:580)
        at 
org.testng.internal.invokers.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:139)
        at 
org.testng.internal.invokers.MethodInvocationHelper.invokeMethodConsideringTimeout(MethodInvocationHelper.java:69)
        at 
org.testng.internal.invokers.ConfigInvoker.invokeConfigurationMethod(ConfigInvoker.java:361)
        at 
org.testng.internal.invokers.ConfigInvoker.invokeConfigurations(ConfigInvoker.java:296)
        at 
org.testng.internal.invokers.TestInvoker.runConfigMethods(TestInvoker.java:823)
        at 
org.testng.internal.invokers.TestInvoker.invokeMethod(TestInvoker.java:590)
        at 
org.testng.internal.invokers.TestInvoker.invokeTestMethod(TestInvoker.java:221)
        at 
org.testng.internal.invokers.MethodRunner.runInSequence(MethodRunner.java:50)
        at 
org.testng.internal.invokers.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:969)
        at 
org.testng.internal.invokers.TestInvoker.invokeTestMethods(TestInvoker.java:194)
        at 
org.testng.internal.invokers.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:148)
        at 
org.testng.internal.invokers.TestMethodWorker.run(TestMethodWorker.java:128)
        at java.base/java.util.ArrayList.forEach(ArrayList.java:1596)
        at org.testng.TestRunner.privateRun(TestRunner.java:829)
        at org.testng.TestRunner.run(TestRunner.java:602)
        at org.testng.SuiteRunner.runTest(SuiteRunner.java:437)
        at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:431)
        at org.testng.SuiteRunner.privateRun(SuiteRunner.java:391)
        at org.testng.SuiteRunner.run(SuiteRunner.java:330)
        at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52)
        at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:95)
        at org.testng.TestNG.runSuitesSequentially(TestNG.java:1256)
        at org.testng.TestNG.runSuitesLocally(TestNG.java:1176)
        at org.testng.TestNG.runSuites(TestNG.java:1099)
        at org.testng.TestNG.run(TestNG.java:1067)
        at 
org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:155)
        at 
org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.executeSingleClass(TestNGDirectoryTestSuite.java:102)
        at 
org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.executeLazy(TestNGDirectoryTestSuite.java:117)
        at 
org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.execute(TestNGDirectoryTestSuite.java:86)
        at 
org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:137)
        at 
org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:385)
        at 
org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:162)
        at 
org.apache.maven.surefire.booter.ForkedBooter.run(ForkedBooter.java:507)
        at 
org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:495)
   
   ```
   
   
   ### Are you willing to submit a PR?
   
   - [ ] I'm willing to submit a PR!
   


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