<commit_before>package org.camunda.bpm.spring.boot.starter.example.cloud.simple;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.annotation.Timed;
import org.springframework.test.context.junit4.SpringRunner;

@RunWith(SpringRunner.class)
@SpringBootTest(classes = { SimpleApplication.class })
public class SimpleApplicationTest {

  @Autowired
  private SimpleApplication application;

  @Test
  @Timed(millis = 10 * 1000)
  public void would_fail_if_process_not_completed_after_10_seconds() throws InterruptedException {
    while (!application.contextClosed && !application.isProcessInstanceFinished()) {
      Thread.sleep(500L);
    }
  }
}<commit_msg>catch InterruptedException (hopefully) fixes #144<commit_after>package org.camunda.bpm.spring.boot.starter.example.cloud.simple;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.annotation.Timed;
import org.springframework.test.context.junit4.SpringRunner;

@RunWith(SpringRunner.class)
@SpringBootTest(classes = { SimpleApplication.class })
public class SimpleApplicationTest {

  private final Logger logger = LoggerFactory.getLogger(this.getClass());

  @Autowired
  private SimpleApplication application;

  @Test
  @Timed(millis = 10 * 1000)
  public void would_fail_if_process_not_completed_after_10_seconds() {
    while (!application.contextClosed && !application.isProcessInstanceFinished()) {
      try {
        Thread.sleep(500L);
      } catch (InterruptedException e) {
        logger.debug("interrupted, that is fine: {}", e.getMessage());
      }
    }
  }
}
{'fraction_non_alphanumeric': 0.10594989561586639, 'fraction_numerical': 0.015135699373695199, 'mean_word_length': 5.476351351351352, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3757110', 'n_tokens_mistral': 578, 'n_tokens_neox': 555, 'n_words': 94}