Example #1
0
        public virtual void testBatchQuery()
        {
            // given
            var batch1 = helper.MigrateProcessInstancesAsync(1);
            var batch2 = helper.MigrateProcessInstancesAsync(1);

            // when
            var list = historyService.CreateHistoricBatchQuery()

                       .ToList();

            // then
            Assert.AreEqual(2, list.Count);

            IList <string> batchIds = new List <string>();

            foreach (var resultBatch in list)
            {
                batchIds.Add(resultBatch.Id);
            }

            Assert.True(batchIds.Contains(batch1.Id));
            Assert.True(batchIds.Contains(batch2.Id));
        }
        public virtual void testQueryOrderByIdAsc()
        {
            // given
            helper.MigrateProcessInstancesAsync(1);
            helper.MigrateProcessInstancesAsync(1);

            // when
            var statistics = managementService.CreateBatchStatisticsQuery()
                             ////.OrderById()
                             /*.Asc()*/

                             .ToList();

            // then
            //verifySorting(statistics, batchStatisticsById());
        }
Example #3
0
        public virtual void seedJobShouldHaveDefaultPriority()
        {
            // when
            var batch = helper.MigrateProcessInstancesAsync(1);

            // then
            var seedJob = helper.GetSeedJob(batch);

            Assert.AreEqual(DefaultJobPriorityProvider.DEFAULT_PRIORITY, seedJob.Priority);
        }
Example #4
0
        public virtual void shouldSuspendBatch()
        {
            // given
            var batch = helper.MigrateProcessInstancesAsync(1);

            // when
            managementService.SuspendBatchById(batch.Id);

            // then
            batch = managementService.CreateBatchQuery()
                    // .SetBatchId(batch.Id)
                    .First();
            Assert.True(batch.Suspended);
        }