Package org.drools.workbench.screens.dtablexls.service

Examples of org.drools.workbench.screens.dtablexls.service.DecisionTableXLSService


    @Test
    @Ignore //TODO {porcelli} have no idea why weld can't start container =/
    public void testCopyAndRenameAndDelete() throws Exception {
        final Bean drlTextEditorServiceBean = (Bean) beanManager.getBeans( DecisionTableXLSService.class ).iterator().next();
        final CreationalContext cc = beanManager.createCreationalContext( drlTextEditorServiceBean );
        final DecisionTableXLSService drlTextEditorService = (DecisionTableXLSService) beanManager.getReference( drlTextEditorServiceBean,
                DecisionTableXLSService.class, cc );
              
        //Copy
        drlTextEditorService.copy(makePath( "/ProjectStructureValid/src/main/resources/org/kie/test/rule1.drl"), "copiedFromRule1.drl", "copied");       
        URL testUrl = this.getClass().getResource( "/ProjectStructureValid/src/main/resources/org/kie/test/copiedFromRule1.drl" );
        assertNotNull(testUrl);
       
        //Rename
        drlTextEditorService.rename(makePath( "/ProjectStructureValid/src/main/resources/org/kie/test/copiedFromRule1.drl"), "renamedFromRule1.drl", "renamed");       
        testUrl = this.getClass().getResource( "/ProjectStructureValid/src/main/resources/org/kie/test/renamedFromRule1.drl" );
        assertNotNull(testUrl);
       
        //Delete
        drlTextEditorService.delete(makePath( "/ProjectStructureValid/src/main/resources/org/kie/test/renamedFromRule1.drl"), "deleted");
        testUrl = this.getClass().getResource( "/ProjectStructureValid/src/main/resources/org/kie/test/renamedFromRule1.drl" );
        assertNull(testUrl);
    }
View Full Code Here

TOP

Related Classes of org.drools.workbench.screens.dtablexls.service.DecisionTableXLSService

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.