Package com.intellij.execution

Examples of com.intellij.execution.ExecutionException


            JSFile jsPsiFile = (JSFile) psiFile;
            TestFileStructurePack pack = TestFileStructureManager.fetchTestFileStructurePackByJsFile(jsPsiFile);
            if (pack != null) {
              List<String> testCases = pack.getTopLevelElements();
              if (testCases.isEmpty()) {
                throw new ExecutionException("No tests found in " + jsPsiFile.getName());
              }
              Map<String, Set<String>> scope = ContainerUtil.newHashMap();
              for (String testCase : testCases) {
                scope.put(testCase, Collections.<String>emptySet());
              }
              return TestFileScope.customScope(scope);
            }
          }
        }
      }
      throw new ExecutionException("Unable to extract tests from " + jsFile.getName());
    }
    if (testType == TestType.TEST_CASE) {
      Map<String, Set<String>> scope = Collections.singletonMap(settings.getTestCaseName(),
                                                                Collections.<String>emptySet());
      return TestFileScope.customScope(scope);
View Full Code Here


  @NotNull
  public static JstdRunProfileState cast(@NotNull RunProfileState state) throws ExecutionException {
    if (state instanceof JstdRunProfileState) {
      return (JstdRunProfileState) state;
    }
    throw new ExecutionException("[Internal error] Cannot run JsTestDriver tests");
  }
View Full Code Here

      }
      catch (Exception e) {
        if (!socket.isClosed()) {
          socket.close();
        }
        throw new ExecutionException(e.getMessage());
      }

      return processHandler;
    }
    catch (Exception e) {
      throw new ExecutionException(e.getMessage());
    }
  }
View Full Code Here

    final String testRunnerPath;
    try {
      testRunnerPath = createTestRunnerFile();
    }
    catch (IOException e) {
      throw new ExecutionException(DartBundle.message("failed.to.create.test.runner", e.getMessage()));
    }

    return doStartProcess(testRunnerPath);
  }
View Full Code Here

  private void checkWorkingDirectory() throws ExecutionException {
    if (myWorkDirectory == null) {
      return;
    }
    if (!myWorkDirectory.exists()) {
      throw new ExecutionException(
        ExecutionBundle.message("run.configuration.error.working.directory.does.not.exist", myWorkDirectory.getAbsolutePath()));
    }
    if (!myWorkDirectory.isDirectory()) {
      throw new ExecutionException(ExecutionBundle.message("run.configuration.error.working.directory.not.directory"));
    }
  }
View Full Code Here

  public List<String> getCodePath() throws ExecutionException {
    try {
      List<String> reporterModuleCodePath = Arrays.asList("-pa", createReporterModuleDirectory());
      return ContainerUtil.concat(reporterModuleCodePath, super.getCodePath());
    } catch (IOException e) {
      throw new ExecutionException("Failed to setup eunit reports environment", e);
    }
  }
View Full Code Here

        result.setLength(result.length() - 2);
      }
      tests = result.toString();
    }
    else {
      throw new ExecutionException("Unknown run config kind");
    }
    return debug ? "{timeout, " + DEBUG_TEST_TIMEOUT + ", [" + tests + "]}" : tests;
  }
View Full Code Here

      writeModifiedConfig(new File(workingDirectory, CONFIG_FILE_NAME), configFile);
      ErlangEunitReporterModule.putReporterModuleTo(tempDirectory);

      return tempDirectory;
    } catch (IOException e) {
      throw new ExecutionException("Failed to setup eunit reports environment", e);
    }
  }
View Full Code Here

    }
    else {
      sdk = ProjectRootManager.getInstance(project).getProjectSdk();
    }
    if (sdk == null) {
      throw new ExecutionException("Erlang SDK is not configured");
    }
    return sdk.getHomePath() + File.separator + "bin" + File.separator + "erl";
  }
View Full Code Here

  @Nullable
  @Override
  public ErlangEntryPoint getEntryPoint() throws ExecutionException {
    ErlangEntryPoint entryPoint = ErlangEntryPoint.fromModuleAndFunction(myConfiguration.getModuleAndFunction(), myConfiguration.getParams());
    if (entryPoint == null) {
      throw new ExecutionException("Invalid entry point");
    }
    return entryPoint;
  }
View Full Code Here

TOP

Related Classes of com.intellij.execution.ExecutionException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.