Examples of TenantId


Examples of com.saasovation.agilepm.domain.model.tenant.TenantId

    public void retryProductDiscussionRequest(RetryProductDiscussionRequestCommand aCommand) {

        ProcessId processId = ProcessId.existingProcessId(aCommand.getProcessId());

        TenantId tenantId = new TenantId(aCommand.getTenantId());

        Product product =
                this.productRepository()
                    .productOfDiscussionInitiationId(
                            tenantId,
View Full Code Here

Examples of com.saasovation.agilepm.domain.model.tenant.TenantId

        try {
            Product product =
                    this.productRepository()
                        .productOfId(
                                new TenantId(aCommand.getTenantId()),
                                new ProductId(aCommand.getProductId()));

            if (product == null) {
                throw new IllegalStateException(
                        "Unknown product of tenant id: "
View Full Code Here

Examples of com.saasovation.agilepm.domain.model.tenant.TenantId

        ApplicationServiceLifeCycle.begin();

        try {
            ProcessId processId = ProcessId.existingProcessId(aCommand.getProcessId());

            TenantId tenantId = new TenantId(aCommand.getTenantId());

            Product product =
                    this.productRepository()
                        .productOfDiscussionInitiationId(
                                tenantId,
View Full Code Here

Examples of com.saasovation.agilepm.domain.model.tenant.TenantId

            String aProductOwnerId,
            String aName,
            String aDescription,
            DiscussionAvailability aDiscussionAvailability) {

        TenantId tenantId = new TenantId(aTenantId);
        ProductId productId = null;

        ApplicationServiceLifeCycle.begin();

        try {
View Full Code Here

Examples of com.saasovation.agilepm.domain.model.tenant.TenantId

    }

    public void commitBacklogItemToSprint(
            CommitBacklogItemToSprintCommand aCommand) {

        TenantId tenantId = new TenantId(aCommand.getTenantId());

        Sprint sprint =
                this.sprintRepository()
                    .sprintOfId(
                            tenantId,
View Full Code Here

Examples of com.saasovation.agilepm.domain.model.tenant.TenantId

    }

    protected ProductOwner persistedProductOwnerForTest() {
        ProductOwner productOwner =
                new ProductOwner(
                        new TenantId("T-12345"),
                        "zoe",
                        "Zoe",
                        "Doe",
                        "zoe@saasovation.com",
                        new Date(new Date().getTime() - (86400000L * 30)));
 
View Full Code Here

Examples of com.saasovation.agilepm.domain.model.tenant.TenantId

    public ProductTest() {
        super();
    }

    public void testCreate() throws Exception {
        TenantId tenantId = new TenantId("T12345");

        Product product =
                new Product(
                        tenantId,
                        new ProductId("P12345"),
View Full Code Here

Examples of com.saasovation.agilepm.domain.model.tenant.TenantId

    }

    public void testSave() throws Exception {
        ProductOwner productOwner =
                new ProductOwner(
                        new TenantId("12345"),
                        "jdoe",
                        "John",
                        "Doe",
                        "jdoe@saasovation.com",
                        new Date());
View Full Code Here

Examples of com.saasovation.agilepm.domain.model.tenant.TenantId

    }

    public void testRemove() {
        ProductOwner productOwner1 =
                new ProductOwner(
                        new TenantId("12345"),
                        "jdoe",
                        "John",
                        "Doe",
                        "jdoe@saasovation.com",
                        new Date());

        ProductOwner productOwner2 =
                new ProductOwner(
                        new TenantId("12345"),
                        "zdoe",
                        "Zoe",
                        "Doe",
                        "zoe@saasovation.com",
                        new Date());

        LevelDBUnitOfWork.start(this.database);
        productOwnerRepository.save(productOwner1);
        productOwnerRepository.save(productOwner2);
        LevelDBUnitOfWork.current().commit();

        LevelDBUnitOfWork.start(this.database);
        productOwnerRepository.remove(productOwner1);
        LevelDBUnitOfWork.current().commit();

        TenantId tenantId = productOwner2.tenantId();

        Collection<ProductOwner> savedProductOwners = productOwnerRepository.allProductOwnersOfTenant(tenantId);
        assertFalse(savedProductOwners.isEmpty());
        assertEquals(1, savedProductOwners.size());
        assertEquals(productOwner2.username(), savedProductOwners.iterator().next().username());
View Full Code Here

Examples of com.saasovation.agilepm.domain.model.tenant.TenantId

    }

    public void testSaveAllRemoveAll() throws Exception {
        ProductOwner productOwner1 =
                new ProductOwner(
                        new TenantId("12345"),
                        "jdoe",
                        "John",
                        "Doe",
                        "jdoe@saasovation.com",
                        new Date());

        ProductOwner productOwner2 =
                new ProductOwner(
                        new TenantId("12345"),
                        "zdoe",
                        "Zoe",
                        "Doe",
                        "zoe@saasovation.com",
                        new Date());

        ProductOwner productOwner3 =
                new ProductOwner(
                        new TenantId("12345"),
                        "jsmith",
                        "John",
                        "Smith",
                        "jsmith@saasovation.com",
                        new Date());

        LevelDBUnitOfWork.start(this.database);
        productOwnerRepository.saveAll(Arrays.asList(new ProductOwner[] { productOwner1, productOwner2, productOwner3 }));
        LevelDBUnitOfWork.current().commit();

        TenantId tenantId = productOwner1.tenantId();

        Collection<ProductOwner> savedProductOwners = productOwnerRepository.allProductOwnersOfTenant(tenantId);
        assertFalse(savedProductOwners.isEmpty());
        assertEquals(3, savedProductOwners.size());
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.