Package org.drools.guvnor.client.rpc

Examples of org.drools.guvnor.client.rpc.PackageConfigData


        impl.createState( "testState2" );
        repositoryAssetService.changePackageState( packagUUID,
                                                   "testState2" );

        PackageConfigData pkg = repositoryPackageService.loadPackageConfig( packagUUID );
        assertEquals( "testState2",
                      pkg.getState() );

        asset = repositoryAssetService.loadRuleAsset( ruleUUID2 );
        assertEquals( "testState2",
                      asset.getState() );
View Full Code Here


                                               false );

        assertTrue( pkg.getNode().getProperty( "drools:binaryUpToDate" ).getBoolean() );
        assertFalse( RuleBaseCache.getInstance().contains( pkg.getUUID() ) );

        PackageConfigData config = repositoryPackageService.loadPackageConfig( pkg.getUUID() );
        repositoryPackageService.savePackage( config );

        assertFalse( pkg.getNode().getProperty( "drools:binaryUpToDate" ).getBoolean() );
        assertFalse( pkg.isBinaryUpToDate() );
        repositoryPackageService.buildPackage( pkg.getUUID(),
View Full Code Here

                      item.getDescription() );

        assertEquals( pkgs.length + 1,
                      repositoryPackageService.listPackages().length );

        PackageConfigData conf = repositoryPackageService.loadPackageConfig( uuid );
        assertEquals( "this is a new package",
                      conf.description );
        assertNotNull( conf.lastModified );

        pkgs = repositoryPackageService.listPackages();
View Full Code Here

        it.updateExternalURI( "ext" );
        DroolsHeader.updateDroolsHeader( "header",
                                                  it );
        impl.getRulesRepository().save();

        PackageConfigData data = repositoryPackageService.loadPackageConfig( uuid );
        assertNotNull( data );

        assertEquals( RulesRepository.DEFAULT_PACKAGE,
                      data.name );
        assertEquals( "header",
View Full Code Here

    public void testArchiveAndUnarchivePackageAndHeader() throws Exception {
        ServiceImplementation impl = getServiceImplementation();
        RepositoryPackageService repositoryPackageService = getRepositoryPackageService();
        String uuid = repositoryPackageService.createPackage( "testArchiveAndUnarchivePackageAndHeader",
                                                              "a desc" );
        PackageConfigData data = repositoryPackageService.loadPackageConfig( uuid );
        PackageItem it = impl.getRulesRepository().loadPackageByUUID( uuid );
        data.archived = true;

        AssetItem rule1 = it.addAsset( "rule_1",
                                       "" );
View Full Code Here

    public void testPackageConfSave() throws Exception {
        RepositoryService impl = getServiceImplementation();
        RepositoryPackageService repositoryPackageService = getRepositoryPackageService();
        String uuid = repositoryPackageService.createPackage( "testPackageConfSave",
                                                              "a desc" );
        PackageConfigData data = repositoryPackageService.loadPackageConfig( uuid );

        data.description = "new desc";
        data.header = "wa";
        data.externalURI = "new URI";
View Full Code Here

        impl.createState( "testState2" );
        repositoryAssetService.changePackageState( packagUUID,
                                                   "testState2" );

        PackageConfigData pkg = repositoryPackageService.loadPackageConfig( packagUUID );
        assertEquals( "testState2",
                      pkg.state );

        asset = repositoryAssetService.loadRuleAsset( ruleUUID2 );
        assertEquals( "testState2",
View Full Code Here

        assertEquals( "X",
                      snaps[0].name );
        assertEquals( "ya",
                      snaps[0].comment );
        assertNotNull( snaps[0].uuid );
        PackageConfigData confSnap = repositoryPackageService.loadPackageConfig( snaps[0].uuid );
        assertEquals( "testSnapshot",
                      confSnap.name );

        repositoryPackageService.createPackageSnapshot( "testSnapshot",
                                                        "Y",
View Full Code Here

                                               false );

        assertTrue( pkg.getNode().getProperty( "drools:binaryUpToDate" ).getBoolean() );
        assertFalse( RuleBaseCache.getInstance().contains( pkg.getUUID() ) );

        PackageConfigData config = repositoryPackageService.loadPackageConfig( pkg.getUUID() );
        repositoryPackageService.savePackage( config );

        assertFalse( pkg.getNode().getProperty( "drools:binaryUpToDate" ).getBoolean() );
        assertFalse( pkg.isBinaryUpToDate() );
        repositoryPackageService.buildPackage( pkg.getUUID(),
View Full Code Here

    @Test
    public void testSavePackageUnarhived() throws SerializationException {
        RepositoryPackageOperations localRepositoryPackageOperations = initSpyingOnRealRepositoryPackageOperations();

        PackageConfigData packageConfigData = createPackageConfigData( true );

        PackageItem packageItem = mock( PackageItem.class );
        initDroolsHeaderCheck( packageItem );
        when( packageItem.isArchived() ).thenReturn( false );
        when( this.rulesRepository.loadPackage( packageConfigData.name ) ).thenReturn( packageItem );
View Full Code Here

TOP

Related Classes of org.drools.guvnor.client.rpc.PackageConfigData

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.