All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.catools.common.config.CConfigToLoadNotDefinedException Maven / Gradle / Ivy

package org.catools.common.config;

import org.catools.common.exception.CRuntimeException;

/**
 * Signals which throws when attempt to work without any configuration.
 */
public class CConfigToLoadNotDefinedException extends CRuntimeException {
    private final static String HELP = "\nTo work you need to load configuration first.\n" +
            "We are using CONFIGS_TO_LOAD to identify which configuration file we should load before start running any tests.\n" +
            "The value(s) of CONFIGS_TO_LOAD should be PATH(s) to resources or file with valid yaml format for CConfigInfoCollection.\n" +
            "Framework attempts to find resource with the provided path first. If resource not found then we try to find a file with provided path\n" +
            "You can set CONFIGS_TO_LOAD value in following ways:\n" +
            "1- If you are using Maven to execute your tests then can either:\n" +
            "\t- Set CONFIGS_TO_LOAD inside your pom file.\n" +
            "\t- Pass CONFIGS_TO_LOAD as Maven command line parameter like -DCONFIGS_TO_LOAD=,\n" +
            "2- If you are using cli then pass the parameter in maven format like -DCONFIGS_TO_LOAD=,\n" +
            "3- Set the value in System Properties\n" +
            "4- Set the value in Environment Variables\n";

    public CConfigToLoadNotDefinedException() {
        super("Configuration is not defined: CONFIGS_TO_LOAD" + HELP);
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy