Пример #1
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void disabledDmn()
        public virtual void disabledDmn()
        {
            processEngineImpl = createProcessEngineImpl(false);

            // simulate manual schema creation by user
            TestHelper.createSchema(processEngineImpl.ProcessEngineConfiguration);

            // let the engine do their schema operations thing
            processEngineImpl.ProcessEngineConfiguration.CommandExecutorSchemaOperations.execute(new SchemaOperationsProcessEngineBuild());
        }
Пример #2
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void readLevelFullfromDB() throws Exception
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET:
        public virtual void readLevelFullfromDB()
        {
//JAVA TO C# CONVERTER WARNING: The original Java variable was marked 'final':
//ORIGINAL LINE: final org.camunda.bpm.engine.impl.cfg.ProcessEngineConfigurationImpl config = config("true", org.camunda.bpm.engine.ProcessEngineConfiguration.HISTORY_FULL);
            ProcessEngineConfigurationImpl config = config("true", ProcessEngineConfiguration.HISTORY_FULL);

            // init the db with level=full
            processEngineImpl = (ProcessEngineImpl)config.buildProcessEngine();

            HistoryLevel historyLevel = config.CommandExecutorSchemaOperations.execute(new DetermineHistoryLevelCmd(config.HistoryLevels));

            assertThat(historyLevel, CoreMatchers.equalTo(org.camunda.bpm.engine.impl.history.HistoryLevel_Fields.HISTORY_LEVEL_FULL));
        }
Пример #3
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void useDefaultLevelAudit() throws Exception
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET:
        public virtual void useDefaultLevelAudit()
        {
            ProcessEngineConfigurationImpl config = config("true", ProcessEngineConfiguration.HISTORY_AUTO);

            // init the db with level=auto -> audit
            processEngineImpl = (ProcessEngineImpl)config.buildProcessEngine();
            // the history Level has been overwritten with audit
            assertThat(config.HistoryLevel, CoreMatchers.equalTo(org.camunda.bpm.engine.impl.history.HistoryLevel_Fields.HISTORY_LEVEL_AUDIT));

            // and this is written to the database
            HistoryLevel databaseLevel = config.CommandExecutorSchemaOperations.execute(new DetermineHistoryLevelCmd(config.HistoryLevels));

            assertThat(databaseLevel, CoreMatchers.equalTo(org.camunda.bpm.engine.impl.history.HistoryLevel_Fields.HISTORY_LEVEL_AUDIT));
        }
Пример #4
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void failWhenExistingHistoryLevelIsNotRegistered()
        public virtual void failWhenExistingHistoryLevelIsNotRegistered()
        {
            // init the db with custom level
            HistoryLevel customLevel = new HistoryLevelAnonymousInnerClass(this);
            ProcessEngineConfigurationImpl config = config("true", "custom");

            config.CustomHistoryLevels = Arrays.asList(customLevel);
            processEngineImpl          = (ProcessEngineImpl)config.buildProcessEngine();

            thrown.expect(typeof(ProcessEngineException));
            thrown.expectMessage("The configured history level with id='99' is not registered in this config.");

            config.CommandExecutorSchemaOperations.execute(new DetermineHistoryLevelCmd(System.Linq.Enumerable.Empty <HistoryLevel>()));
        }
Пример #5
0
        // make sure schema is dropped
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @After public void cleanup()
        public virtual void cleanup()
        {
            TestHelper.dropSchema(processEngineImpl.ProcessEngineConfiguration);
            processEngineImpl.close();
            processEngineImpl = null;
        }