<commit_before>package org.jsystemtest.plugin;

import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;

import org.apache.maven.plugin.AbstractMojo;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugin.MojoFailureException;
import org.apache.maven.project.MavenProject;
import org.apache.tools.ant.DefaultLogger;
import org.apache.tools.ant.Project;
import org.apache.tools.ant.ProjectHelper;
import org.jsystemtest.plugin.MultipleScenarioSuitExecutionFileParser.Execution;

import jsystem.framework.FrameworkOptions;
import jsystem.framework.JSystemProperties;
import jsystem.framework.scenario.RunningProperties;
import jsystem.runner.AntExecutionListener;
import jsystem.utils.StringUtils;

/**
 * 
 * This plug in purpose is to execute JSystem scenarios
 * 
 * @author <NAME>
 * 
 * @goal run
 * @requiresProject true
 * 
 * @phase integration-test
 */
public class JSystemMojo extends AbstractMojo {

	private static final String SCENARIO_PATH = "target/classes/scenarios";
	private static final String SUT_PATH = "target/classes/sut";
	private static final String TEST_PROPERTIES_FILE_EMPTY = ".testPropertiesFile_Empty";
	private static final String DEFAULT_REPORTERS = "jsystem.extensions.report.difido.HtmlReporter;jsystem.framework.report.SystemOutTestReporter;jsystem.extensions.report.xml.XmlReporter;jsystem.extensions.report.junit.JUnitReporter";
	private static final String DELIMITER = ",";

	/**
	 * The current project representation.
	 * 
	 * @parameter expression="${project}"
	 * @required
	 * @readonly
	 */
	private MavenProject mavenProject;

	/**
	 * @parameter expression="${scenario}"
	 */
	private String scenario;

	/**
	 * @parameter expression="${sut}"
	 */
	private String sut;

	/**
	 * @parameter expression="${xmlFile}"
	 */
	private String xmlFile;

	/**
	 */
	public void execute() throws MojoExecutionException, MojoFailureException {
		if (null == scenario) {
			getLog().error("Please specify a valid scenario name. Scenario can't be " + scenario);
			throw new MojoExecutionException("Please specify a valid scenario name. Scenario can't be " + scenario);
		}
		if (null == sut) {
			getLog().error("Please specify a valid sut name. Sut can't be " + sut);<commit_msg>Fixed deprected way of defining plugin parameters. issue #366<commit_after>package org.jsystemtest.plugin;

import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;

import org.apache.maven.plugin.AbstractMojo;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugin.MojoFailureException;
import org.apache.maven.project.MavenProject;
import org.apache.tools.ant.DefaultLogger;
import org.apache.tools.ant.Project;
import org.apache.tools.ant.ProjectHelper;
import org.jsystemtest.plugin.MultipleScenarioSuitExecutionFileParser.Execution;

import jsystem.framework.FrameworkOptions;
import jsystem.framework.JSystemProperties;
import jsystem.framework.scenario.RunningProperties;
import jsystem.runner.AntExecutionListener;
import jsystem.utils.StringUtils;

/**
 * 
 * This plug in purpose is to execute JSystem scenarios
 * 
 * @author <NAME>
 * 
 * @goal run
 * @requiresProject true
 * 
 * @phase integration-test
 */
public class JSystemMojo extends AbstractMojo {

	private static final String SCENARIO_PATH = "target/classes/scenarios";
	private static final String SUT_PATH = "target/classes/sut";
	private static final String TEST_PROPERTIES_FILE_EMPTY = ".testPropertiesFile_Empty";
	private static final String DEFAULT_REPORTERS = "jsystem.extensions.report.difido.HtmlReporter;jsystem.framework.report.SystemOutTestReporter;jsystem.extensions.report.xml.XmlReporter;jsystem.extensions.report.junit.JUnitReporter";
	private static final String DELIMITER = ",";

	/**
	 * The current project representation.
	 * 
	 * @parameter property="project"
	 * @required
	 * @readonly
	 */
	private MavenProject mavenProject;

	/**
	 * @parameter property="scenario"
	 */
	private String scenario;

	/**
	 * @parameter property="sut"
	 */
	private String sut;

	/**
	 * @parameter property="xmlFile"
	 */
	private String xmlFile;

	/**
	 */
	public void execute() throws MojoExecutionException, MojoFailureException {
		if (null == scenario) {
			getLog().error("Please specify a valid scenario name. Scenario can't be " + scenario);
			throw new MojoExecutionException("Please specify a valid scenario name. Scenario can't be " + scenario);
		}
		if (null == sut) {
			getLog().error("Please specify a valid sut name. Sut can't be " + sut);
{'fraction_non_alphanumeric': 0.10782608695652174, 'fraction_numerical': 0.0006521739130434783, 'mean_word_length': 5.022251308900524, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 6}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6207854', 'n_tokens_mistral': 1401, 'n_tokens_neox': 1305, 'n_words': 321}