on 2018 Feb 27 10:05 AM
Hi,
I am using PowerMockito to mock Registry.class, and wherever I am doing this, I am getting the below exception.
Caused by: java.lang.ClassCastException: de.hybris.platform.util.logging.log4j2.HybrisLoggerContext cannot be cast to de.hybris.platform.util.logging.log4j2.HybrisLoggerContext at de.hybris.platform.util.logging.HybrisLogger.setLevel(HybrisLogger.java:512) at org.apache.log4j.PropertyConfigurator.parseCategory(PropertyConfigurator.java:753) at org.apache.log4j.PropertyConfigurator.parseCatsAndRenderers(PropertyConfigurator.java:672) at org.apache.log4j.PropertyConfigurator.doConfigure(PropertyConfigurator.java:516) at de.hybris.platform.core.Log4JUtils.readConfig(Log4JUtils.java:103) at de.hybris.platform.core.Log4JUtils.startup(Log4JUtils.java:56) at de.hybris.platform.core.Registry.(Registry.java:80)
Can someone help me with resolution for this?
Please note that the JUNIT is running successfully in ee, but fails only when running through the ant command "ant unittests".
I am using powerMock version "1.6.1" and I am on Hybris 6.6
Thanks,
Request clarification before answering.
| User | Count |
|---|---|
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.