<commit_before><?php

class CM_Usertext_Filter_EmoticonTest extends CMTest_TestCase {

	public function tearDown() {
		CMTest_TH::clearEnv();
	}

	public function testProcess() {
		$emoticonId = CM_Db_Db::insert(TBL_CM_EMOTICON, array('code' => ':smiley:', 'codeAdditional' => ':),:-)', 'file' => '1.png'));
		$text = 'foo :) bar :smiley:';
		$expected =
				'foo <img src="/layout/1/0/img/emoticon/1.png" class="emoticon emoticon-' . $emoticonId .
						'" title=":smiley:" /> bar <img src="/layout/1/0/img/emoticon/1.png" class="emoticon emoticon-' . $emoticonId .
						'" title=":smiley:" />';
		$filter = new CM_Usertext_Filter_Emoticon();
		$actual = $filter->transform($text, $this->_getRender());

		$this->assertSame($expected, $actual);
	}
}
<commit_msg>Fixed CM_Usertext_Filter_EmoticonTest:<commit_after><?php

class CM_Usertext_Filter_EmoticonTest extends CMTest_TestCase {

	public function tearDown() {
		CMTest_TH::clearEnv();
	}

	public function testProcess() {
		$site = $this->_getSite();
		$siteType = $site->getType();
		$emoticonId = CM_Db_Db::insert(TBL_CM_EMOTICON, array('code' => ':smiley:', 'codeAdditional' => ':),:-)', 'file' => '1.png'));
		$text = 'foo :) bar :smiley:';
		$expected =
				'foo <img src="/layout/' . $siteType . '/0/img/emoticon/1.png" class="emoticon emoticon-' . $emoticonId .
						'" title=":smiley:" /> bar <img src="/layout/' . $siteType . '/0/img/emoticon/1.png" class="emoticon emoticon-' .
						$emoticonId .
						'" title=":smiley:" />';
		$filter = new CM_Usertext_Filter_Emoticon();
		$actual = $filter->transform($text, $this->_getRender());

		$this->assertSame($expected, $actual);
	}
}

{'fraction_non_alphanumeric': 0.20520581113801453, 'fraction_numerical': 0.007263922518159807, 'mean_word_length': 4.473509933774834, 'pattern_counts': {'":': 4, '<': 9, '<?xml version=': 0, '>': 21, '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': '7480881', 'n_tokens_mistral': 670, 'n_tokens_neox': 611, 'n_words': 101}