<commit_before><template>
  <div class="container">
    <div class="columns">
      <div class="test-output">
        <textarea v-model="testOutput"></textarea>
      </div>
      <div class="results">
        <div class="files"><pre>{{files}}</pre></div>
        <div class="cli-command">c</div>
        <div class="phpstorm-command">d</div>
      </div>
    </div>
  </div>
</template>
<script>
  /** @class Page */
  export default {
    data() {
      return {
        testOutput: '',
      };
    },
    methods: {
      onTestOutputChange() {
      },
    },
    computed: {
      files() {
        const pattern = /\s+\d+\) ([\w\\\\:]+)/g;
        let ret = '';
        let match;
        // eslint-disable-next-line no-cond-assign
        while ((match = pattern.exec(this.testOutput)) !== null) {
          ret += `${match[1]}\n`;
        }
        return ret;
      },
    },
    components: {},<commit_msg>Show PhpStorm and CLI output for phpunit<commit_after><template>
  <div class="container">
    <div class="columns">
      <div class="test-output">
        <textarea v-model="testOutput"></textarea>
      </div>
      <div class="results">
        <div class="files"><pre>{{ matches.files }}</pre></div>
        <div class="phpstorm-command">{{ matches.phpstormCommand }}</div>
        <div class="cli-command"><pre>{{ matches.cliCommand }}</pre></div>
      </div>
    </div>
  </div>
</template>
<script>
  /** @class Page */
  export default {
    data() {
      return {
        testOutput: '',
      };
    },
    computed: {
      matches() {
        const pattern = /\s+\d+\) ([\w\\\\:]+)/g;
        let ret = '';
        let match;
        const matches = [];
        // eslint-disable-next-line no-cond-assign
        while ((match = pattern.exec(this.testOutput)) !== null) {
          matches.push(match[1]);
        }
        const escapeBackslahes = input => input.replace(/\\/g, '\\\\');
        const phpstormCommand = `--filter="/^(${escapeBackslahes(matches.join('|'))})/"`;
        matches.sort();
        return {
          files: matches.join("\n"),
          phpstormCommand,
          cliCommand: `phpunit ${escapeBackslahes(phpstormCommand)}`,
        }
      },
    },
    components: {},
{'fraction_non_alphanumeric': 0.2, 'fraction_numerical': 0.0008968609865470852, 'mean_word_length': 1.9866131191432397, 'pattern_counts': {'":': 0, '<': 47, '<?xml version=': 0, '>': 48, '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': '2096976', 'n_tokens_mistral': 706, 'n_tokens_neox': 689, 'n_words': 130}