<commit_before>#!/bin/bash
# This script assumes it's running in the root of an oe-build, and that it is being called
# after a build has completed succesfully.
# The propose of the script is to execute tests against code contained in the depoy/sysroots output.
# It is designed to be called from within and without the CI system.

set -e

if [ -z $WORKSPACE ]; then
	echo "Setting WORKSPACE TO `pwd`"
	WORKSPACE=`pwd`
fi

cd $WORKSPACE

JAVA_OE_BUILD_DIR=$WORKSPACE/oe-tmp/sysroots/java
TEST_ROOT=$WORKSPACE/tests
BUILD_TOOLS=$TEST_ROOT/bug-osgi/com.buglabs.osgi.build
DEPS_DIR=$TEST_ROOT/subjects

if ! -d $TEST_ROOT ]; then
	mkdir $TEST_ROOT
fi

if [ ! -d $DEPS_DIR ]; then
	mkdir $DEPS_DIR
else 
	rm -Rf $DEPS_DIR
	mkdir $DEPS_DIR
fi

echo "Copying oe-built jars from $JAVA_OE_BUILD_DIR"
cp $JAVA_OE_BUILD_DIR/* $DEPS_DIR

if [ ! -f $DEPS_DIR/junit-osgi-4.9b2.jar ]; then
	wget --no-check-certificate -P $DEPS_DIR https://github.com/downloads/buglabs/bug-osgi/junit-osgi-4.9b2.jar
fi 

if [ ! -d $TEST_ROOT ]; then
	mkdir $TEST_ROOT
fi

if [ ! -d $TEST_ROOT/junit-reports ]; then
	mkdir $TEST_ROOT/junit-reports
fi

cd $TEST_ROOT

if [ ! -d bug-osgi ]; then
	git clone <EMAIL>:buglabs/bug-osgi.git
fi<commit_msg>oe-buglabs: typo<commit_after>#!/bin/bash
# This script assumes it's running in the root of an oe-build, and that it is being called
# after a build has completed succesfully.
# The propose of the script is to execute tests against code contained in the depoy/sysroots output.
# It is designed to be called from within and without the CI system.

set -e

if [ -z $WORKSPACE ]; then
	echo "Setting WORKSPACE TO `pwd`"
	WORKSPACE=`pwd`
fi

cd $WORKSPACE

JAVA_OE_BUILD_DIR=$WORKSPACE/oe-tmp/sysroots/java
TEST_ROOT=$WORKSPACE/tests
BUILD_TOOLS=$TEST_ROOT/bug-osgi/com.buglabs.osgi.build
DEPS_DIR=$TEST_ROOT/subjects

if [ ! -d $TEST_ROOT ]; then
	mkdir $TEST_ROOT
fi

if [ ! -d $DEPS_DIR ]; then
	mkdir $DEPS_DIR
else 
	rm -Rf $DEPS_DIR
	mkdir $DEPS_DIR
fi

echo "Copying oe-built jars from $JAVA_OE_BUILD_DIR"
cp $JAVA_OE_BUILD_DIR/* $DEPS_DIR

if [ ! -f $DEPS_DIR/junit-osgi-4.9b2.jar ]; then
	wget --no-check-certificate -P $DEPS_DIR https://github.com/downloads/buglabs/bug-osgi/junit-osgi-4.9b2.jar
fi 

if [ ! -d $TEST_ROOT ]; then
	mkdir $TEST_ROOT
fi

if [ ! -d $TEST_ROOT/junit-reports ]; then
	mkdir $TEST_ROOT/junit-reports
fi

cd $TEST_ROOT

if [ ! -d bug-osgi ]; then
	git clone <EMAIL>:buglabs/bug-osgi.git
fi
{'fraction_non_alphanumeric': 0.11366434140336479, 'fraction_numerical': 0.004924086992203529, 'mean_word_length': 4.016460905349795, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1188196', 'n_tokens_mistral': 1007, 'n_tokens_neox': 968, 'n_words': 270}