<commit_before>package com.bugielmarek.timetable.tests.utils;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;

public class TestUtils {

	 
	 public static String createStringWithLength(int length){
		 	StringBuilder sb = new StringBuilder();
		 	for(int i=0; i<length; i++){
		 		sb.append("a");
		 	}
		 	return sb.toString();
	 }
	 
	/* public static byte[] convertObjectToJsonBytes(Object object) throws IOException {
	        ObjectMapper mapper = new ObjectMapper();
	        mapper.setSerializationInclusion(JsonInclude.Include.NON_NULL);
	        return mapper.writeValueAsBytes(object);
	    }*/
	 
	 public static String asJsonString(Object object) throws JsonProcessingException{
		 ObjectMapper mapper = new ObjectMapper();
		 mapper.setSerializationInclusion(JsonInclude.Include.NON_NULL);
		 return mapper.writeValueAsString(object);
	 }
}<commit_msg>Delete byte[] method, was superfluous<commit_after>package com.bugielmarek.timetable.tests.utils;

import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;

public class TestUtils {

	 public static String createStringWithLength(int length){
		 	StringBuilder sb = new StringBuilder();
		 	for(int i=0; i<length; i++){
		 		sb.append("a");
		 	}
		 	return sb.toString();
	 }
	 
	 public static String asJsonString(Object object) throws JsonProcessingException{
		 ObjectMapper mapper = new ObjectMapper();
		 mapper.setSerializationInclusion(JsonInclude.Include.NON_NULL);
		 return mapper.writeValueAsString(object);
	 }
}
{'fraction_non_alphanumeric': 0.09865732632807939, 'fraction_numerical': 0.0011675423234092236, 'mean_word_length': 4.829931972789115, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 6}, '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': '6816593', 'n_tokens_mistral': 543, 'n_tokens_neox': 456, 'n_words': 100}