Exemple #1
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void dontCreateNewJobsWhileReDeployment()
        public virtual void dontCreateNewJobsWhileReDeployment()
        {
            testRule.deployForTenant(TENANT_ONE, PROCESS);
            testRule.deployForTenant(TENANT_TWO, PROCESS);
            testRule.deployForTenant(TENANT_ONE, PROCESS);

            JobQuery query = managementService.createJobQuery();

            assertThat(query.tenantIdIn(TENANT_ONE).count(), @is(1L));
            assertThat(query.tenantIdIn(TENANT_TWO).count(), @is(1L));
        }
Exemple #2
0
        public virtual void testQueryAuthenticatedTenants()
        {
            identityService.setAuthentication("user", null, Arrays.asList(TENANT_ONE, TENANT_TWO));

            JobQuery query = managementService.createJobQuery();

            assertThat(query.count(), @is(3L));
            assertThat(query.tenantIdIn(TENANT_ONE).count(), @is(1L));
            assertThat(query.tenantIdIn(TENANT_TWO).count(), @is(1L));
            assertThat(query.withoutTenantId().count(), @is(1L));
        }
Exemple #3
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void deleteJobsWhileUndeployment()
        public virtual void deleteJobsWhileUndeployment()
        {
            Deployment deploymentForTenantOne = testRule.deployForTenant(TENANT_ONE, PROCESS);
            Deployment deploymentForTenantTwo = testRule.deployForTenant(TENANT_TWO, PROCESS);

            JobQuery query = managementService.createJobQuery();

            assertThat(query.tenantIdIn(TENANT_ONE).count(), @is(1L));
            assertThat(query.tenantIdIn(TENANT_TWO).count(), @is(1L));

            repositoryService.deleteDeployment(deploymentForTenantOne.Id, true);

            assertThat(query.tenantIdIn(TENANT_ONE).count(), @is(0L));
            assertThat(query.tenantIdIn(TENANT_TWO).count(), @is(1L));

            repositoryService.deleteDeployment(deploymentForTenantTwo.Id, true);

            assertThat(query.tenantIdIn(TENANT_ONE).count(), @is(0L));
            assertThat(query.tenantIdIn(TENANT_TWO).count(), @is(0L));
        }