Examples of executeTarget()


Examples of org.apache.tools.ant.Project.executeTarget()

        PrintStream err = System.err;
        System.setOut(new PrintStream(new DemuxOutputStream(project, false)));
        System.setErr(new PrintStream(new DemuxOutputStream(project, true)));

        try {
            project.executeTarget("testDemux");
        } finally {
            System.setOut(out);
            System.setErr(err);
        }
    }
View Full Code Here

Examples of org.apache.tools.ant.Project.executeTarget()

            if (target == null) {
                target = project.getDefaultTarget();
            }

            project.executeTarget(target);
        } catch (BuildException e) {
            error = e;
            throw new ExecutionException(e);
        } finally {
            project.fireBuildFinished(error);
View Full Code Here

Examples of org.apache.tools.ant.Project.executeTarget()

              ant.addBuildListener(log);
              ProjectHelper helper = new ProjectHelperImpl();
              ant.init();
              helper.parse(ant, antFile);
              LOGGER.debug(" -- Executing Ant task ...");   
              ant.executeTarget("backup");
          LOGGER.debug(" -- Ant task Executed ...");
              LOGGER.debug(" -- Deleting ant file ...");   
          antFile.delete();
          LOGGER.info(" - END OF BACKUP");   
        } catch (IOException e) {
View Full Code Here

Examples of org.apache.tools.ant.Project.executeTarget()

               
                project.init();
                // setup the project
                addMXMLCTarget(project);
                // compile the mxml
                project.executeTarget("compile");
                if (swfFile.exists() && htmlFile.exists())                   
                    writeWrapperHtml(resp, out, htmlFile);
                else
                {
                    out.print("<h1>Internal error.</h1><br/>Generated swf and wrapper couldn't be found.</html>");
View Full Code Here

Examples of org.apache.tools.ant.Project.executeTarget()

        }
        AbstractCloverMojo.registerCloverAntTasks(antProject, getLog());
        ProjectHelper.configureProject(antProject, reportDescriptor);
        antProject.setBaseDir(project.getBasedir());
        String target = isHistoricalDirectoryValid(output) && (historyOut != null) ? "historical" : "current";
        antProject.executeTarget(target);
    }

    private void addMavenProperties(final Project antProject) {
        final Map properties = getProject().getProperties();
View Full Code Here

Examples of org.apache.tools.ant.Project.executeTarget()

    private boolean startSuite(AntUnitExecutionNotifier notifier) {
        getCurrentProject().fireBuildStarted();
        if (hasSuiteSetUp) {
            try {
                Project newProject = getCleanProject();
                newProject.executeTarget(SUITESETUP);
            } catch (BuildException e) {
                notifier.fireStartTest(SUITESETUP);
                fireFailOrError(SUITESETUP, e, notifier);
                return false;
            }
View Full Code Here

Examples of org.apache.tools.ant.Project.executeTarget()

            // is reached.
            notifier.fireEndTest(name);
            // clean up
            if (hasTearDown) {
                try {
                    newProject.executeTarget(TEARDOWN);
                } catch (final BuildException e) {
                    fireFailOrError(name, e, notifier);
                }
            }
        }
View Full Code Here

Examples of org.apache.tools.ant.Project.executeTarget()

     */
    private void endSuite(Throwable caught, AntUnitExecutionNotifier notifier) {
        if (hasSuiteTearDown) {
            try {
                Project newProject = getCleanProject();
                newProject.executeTarget(SUITETEARDOWN);
            } catch (BuildException e) {
                notifier.fireStartTest(SUITETEARDOWN);
                fireFailOrError(SUITETEARDOWN, e, notifier);
            }
        }
View Full Code Here

Examples of org.apache.tools.ant.Project.executeTarget()

            p.fireBuildStarted();
            p.init();
            ProjectHelper helper = ProjectHelper.getProjectHelper();
            p.addReference("ant.projectHelper", helper);
            helper.parse(p, buildFile);
            p.executeTarget(p.getDefaultTarget());
            p.fireBuildFinished(null);
        } catch (BuildException e) {
            p.fireBuildFinished(e);
            fail(e.getMessage());           
        }
View Full Code Here

Examples of org.apache.tools.ant.Project.executeTarget()

                target = theProject.getDefaultTarget();
            }
            if (getLogger().isDebugEnabled()) {
                getLogger().debug("executing target "+target+" with log priority level "+myPriorityLevel);
            }
            theProject.executeTarget(target);
            theProject.fireBuildFinished(mySAXException);
        } catch (Exception e) {
            getLogger().error(e.getMessage(), e);
            while (!myStack.isEmpty()) {
                String tag = (String) myStack.pop();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.