diff --git a/components/device-mgt-extensions/org.wso2.carbon.device.mgt.extensions.push.notification.provider.mqtt/src/test/java/org/wso2/carbon/device/mgt/extensions/push/notification/provider/mqtt/CarbonContextInitializationUtil.java b/components/device-mgt-extensions/org.wso2.carbon.device.mgt.extensions.push.notification.provider.mqtt/src/test/java/org/wso2/carbon/device/mgt/extensions/push/notification/provider/mqtt/CarbonContextInitializationUtil.java index b69482751ac..8ddf3dea629 100644 --- a/components/device-mgt-extensions/org.wso2.carbon.device.mgt.extensions.push.notification.provider.mqtt/src/test/java/org/wso2/carbon/device/mgt/extensions/push/notification/provider/mqtt/CarbonContextInitializationUtil.java +++ b/components/device-mgt-extensions/org.wso2.carbon.device.mgt.extensions.push.notification.provider.mqtt/src/test/java/org/wso2/carbon/device/mgt/extensions/push/notification/provider/mqtt/CarbonContextInitializationUtil.java @@ -29,7 +29,7 @@ public class CarbonContextInitializationUtil { private final static String CARBON_HOME = "carbon.home"; public static void initializeCarbonContext() { - if (System.getProperty("carbon.home") == null) { + if (System.getProperty(CARBON_HOME) == null) { File file = new File("src/test/resources"); if (file.exists()) { System.setProperty(CARBON_HOME, file.getAbsolutePath());