<commit_before>#!/bin/bash -l

set -e

export PATH=./bin:$PATH
export RAILS_ENV=test
export BUNDLE_WITHOUT=development

CORES=$(grep -c ^processor /proc/cpuinfo 2>/dev/null || sysctl -n hw.ncpu)
BUNDLE_JOBS=$((CORES-1))

CI_PIPELINE_COUNTER=${GO_PIPELINE_LABEL-0}
CI_EXECUTOR_NUMBER=${EXECUTOR_NUMBER-0}

bundle exec bundle install --jobs $BUNDLE_JOBS

if [ -n "$GO_PIPELINE_NAME" ]; then
  # set up test DB if running on CI
  mv spec/dummy/config/database{-ci,}.yml
fi

bundle exec rake db:drop db:create db:migrate
bundle exec rspec
bundle exec cucumber<commit_msg>Use documentation format for tests<commit_after>#!/bin/bash -l

set -e

export PATH=./bin:$PATH
export RAILS_ENV=test
export BUNDLE_WITHOUT=development

CORES=$(grep -c ^processor /proc/cpuinfo 2>/dev/null || sysctl -n hw.ncpu)
BUNDLE_JOBS=$((CORES-1))

CI_PIPELINE_COUNTER=${GO_PIPELINE_LABEL-0}
CI_EXECUTOR_NUMBER=${EXECUTOR_NUMBER-0}

bundle exec bundle install --jobs $BUNDLE_JOBS

if [ -n "$GO_PIPELINE_NAME" ]; then
  # set up test DB if running on CI
  mv spec/dummy/config/database{-ci,}.yml
fi

bundle exec rake db:drop db:create db:migrate
bundle exec rspec --format=documentation
bundle exec cucumber
{'fraction_non_alphanumeric': 0.12139219015280135, 'fraction_numerical': 0.006791171477079796, 'mean_word_length': 5.140625, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, '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': '3444386', 'n_tokens_mistral': 474, 'n_tokens_neox': 460, 'n_words': 112}