Package com.dtolabs.rundeck.core.common

Examples of com.dtolabs.rundeck.core.common.FrameworkProject


    }

    public void setUp() {
        super.setUp();
        final Framework frameworkInstance = getFrameworkInstance();
        final FrameworkProject frameworkProject = frameworkInstance.getFrameworkProjectMgr().createFrameworkProject(
            PROJ_NAME);
        File resourcesfile = new File(frameworkProject.getNodesResourceFilePath());
        //copy test nodes to resources file
        try {
            FileUtils.copyFileStreams(new File("src/test/resources/com/dtolabs/rundeck/core/common/test-nodes1.xml"),
                resourcesfile);
        } catch (IOException e) {
View Full Code Here


    }

    public void setUp() {
        super.setUp();
        final Framework frameworkInstance = getFrameworkInstance();
        final FrameworkProject frameworkProject = frameworkInstance.getFrameworkProjectMgr().createFrameworkProject(
            PROJ_NAME);
        File resourcesfile = new File(frameworkProject.getNodesResourceFilePath());
        //copy test nodes to resources file
        try {
            FileUtils.copyFileStreams(new File("src/test/resources/com/dtolabs/rundeck/core/common/test-nodes1.xml"),
                resourcesfile);
        } catch (IOException e) {
View Full Code Here

    protected void setUp()  {
        super.setUp();
        testFramework = getFrameworkInstance();
        testnode=testFramework.getFrameworkNodeName();
        final FrameworkProject frameworkProject = testFramework.getFrameworkProjectMgr().createFrameworkProject(
            TEST_PROJECT);
        File resourcesfile = new File(frameworkProject.getNodesResourceFilePath());
        //copy test nodes to resources file
        try {
            FileUtils.copyFileStreams(new File("src/test/resources/com/dtolabs/rundeck/core/common/test-nodes1.xml"),
                resourcesfile);
        } catch (IOException e) {
View Full Code Here

        }
    }

    public void testExecuteWorkflow() throws Exception {
        {
            final FrameworkProject frameworkProject = testFramework.getFrameworkProjectMgr().getFrameworkProject(
                TEST_PROJECT);
            final INodeSet nodes = frameworkProject.getNodeSet();
            assertNotNull(nodes);
            assertEquals(2, nodes.getNodes().size());

        }
View Full Code Here

        setup.executeAction();

        assertTrue("project did not exist", getFrameworkInstance().getFrameworkProjectMgr().existsFrameworkProject(
            PROJECT));

        final FrameworkProject d = getFrameworkInstance().getFrameworkProjectMgr().createFrameworkProject(PROJECT);
        assertEquals("project name did not match", d.getName(), PROJECT);
    }
View Full Code Here

        return new TestSuite(TestDataContextUtils.class);
    }

    protected void setUp() {
        super.setUp();
        FrameworkProject d = getFrameworkInstance().getFrameworkProjectMgr().createFrameworkProject(
            TEST_PROJECT);
        final File dir = new File(d.getBaseDir(), "var");
        assertTrue(dir.mkdirs());
        testfile1 = new File(dir, "test-file.sh");
        try {
            assertTrue(testfile1.createNewFile());
            final FileWriter writer = new FileWriter(testfile1);
View Full Code Here

    }

    protected void tearDown() throws Exception {
        testfile1.delete();
        FrameworkProject d = getFrameworkInstance().getFrameworkProjectMgr().createFrameworkProject(
            TEST_PROJECT);
        FileUtils.deleteDir(d.getBaseDir());
        getFrameworkInstance().getFrameworkProjectMgr().remove(TEST_PROJECT);

    }
View Full Code Here

* @author Greg Schueler <a href="mailto:greg@dtosolutions.com">greg@dtosolutions.com</a>
*/
public class ScriptDataContextUtil {

    private static File getVarDirForProject(final Framework framework, final String projectName) {
        final FrameworkProject frameworkProject = framework.getFrameworkProjectMgr().getFrameworkProject(
            projectName);
        return new File(Constants.getBaseVar(frameworkProject.getBaseDir().getAbsolutePath()));
    }
View Full Code Here

    }

    public void setUp() {
        super.setUp();
        final Framework frameworkInstance = getFrameworkInstance();
        final FrameworkProject frameworkProject = frameworkInstance.getFrameworkProjectMgr().createFrameworkProject(
            PROJ_NAME);
        File resourcesfile = new File(frameworkProject.getNodesResourceFilePath());
        //copy test nodes to resources file
        try {
            FileUtils.copyFileStreams(new File("src/test/resources/com/dtolabs/rundeck/core/common/test-nodes1.xml"),
                resourcesfile);
        } catch (IOException e) {
View Full Code Here

    public boolean hasSingleProject() {
        return framework.getFrameworkProjectMgr().listFrameworkProjects().size() == 1;
    }

    public String getSingleProjectName() {
        final FrameworkProject project =
            (FrameworkProject) framework.getFrameworkProjectMgr().listFrameworkProjects().iterator().next();
        return project.getName();
    }
View Full Code Here

TOP

Related Classes of com.dtolabs.rundeck.core.common.FrameworkProject

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.