if (result) {
setMessage(null);
setErrorMessage(null);
IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot();
StringSubstitution stringSubstitution = getStringSubstitution(root);
String location = fMainModuleText.getText();
try {
String identifier = launchConfig.getType().getIdentifier();
if (identifier.equals(Constants.ID_PYTHON_UNITTEST_LAUNCH_CONFIGURATION_TYPE)
|| identifier.equals(Constants.ID_JYTHON_UNITTEST_LAUNCH_CONFIGURATION_TYPE)
|| identifier.equals(Constants.ID_IRONPYTHON_UNITTEST_LAUNCH_CONFIGURATION_TYPE)
|| identifier.equals(Constants.ID_PYTHON_COVERAGE_LAUNCH_CONFIGURATION_TYPE)) {
//may have multiple files selected for the run for unitest and code-coverage
for (String loc : StringUtils.splitAndRemoveEmptyTrimmed(location, '|')) {
String expandedLocation = stringSubstitution.performStringSubstitution(loc);
File file = new File(expandedLocation);
if (!file.exists()) {
setErrorMessage(com.aptana.shared_core.string.StringUtils.format("The file \"%s\" does not exist.", file));
result = false;
break;
}
}
} else {
String expandedLocation = stringSubstitution.performStringSubstitution(location);
File file = new File(expandedLocation);
if (!file.exists()) {
setErrorMessage(com.aptana.shared_core.string.StringUtils.format("The file \"%s\" does not exist.", file));
result = false;