<commit_before><?php

class EncryptionTest extends PHPUnit_Framework_TestCase
{
    private $Encryption;
    private $string;
    private $encrypted;

    public function setUp()
    {
        $this->Encryption = new Advandz\Component\Encryption();
    }

    /**
     * @covers Encryption::encrypt
     */
    public function testEncrypt()
    {
        $key = $this->Encryption->generateKey();

        $this->Encryption->setKey($key);

        $string = 'test';

        $this->assertTrue(is_string($this->Encryption->encrypt($string)));
    }

    /**
     * @covers Encryption::decrypt
     */
    public function testDecrypt()
    {
        $key = '321626b697b7a5936b8e720dfcdbbdda';
        $expected = 'test';
        $encrypted = '<KEY>';

        $this->Encryption->setKey($key);
        
        $this->assertSame($expected, $this->Encryption->decrypt($encrypted));
    }

    /**
     * @covers Encryption::generateKey
     */
    public function testGenerateKey()
    {
        $this->assertTrue(is_string($this->Encryption->generateKey()));
    }
}
<commit_msg>Apply fixes from StyleCI (#17)<commit_after><?php

class EncryptionTest extends PHPUnit_Framework_TestCase
{
    private $Encryption;
    private $string;
    private $encrypted;

    public function setUp()
    {
        $this->Encryption = new Advandz\Component\Encryption();
    }

    /**
     * @covers Encryption::encrypt
     */
    public function testEncrypt()
    {
        $key = $this->Encryption->generateKey();

        $this->Encryption->setKey($key);

        $string = 'test';

        $this->assertTrue(is_string($this->Encryption->encrypt($string)));
    }

    /**
     * @covers Encryption::decrypt
     */
    public function testDecrypt()
    {
        $key       = '321626b697b7a5936b8e720dfcdbbdda';
        $expected  = 'test';
        $encrypted = '<KEY>';

        $this->Encryption->setKey($key);

        $this->assertSame($expected, $this->Encryption->decrypt($encrypted));
    }

    /**
     * @covers Encryption::generateKey
     */
    public function testGenerateKey()
    {
        $this->assertTrue(is_string($this->Encryption->generateKey()));
    }
}

{'fraction_non_alphanumeric': 0.15096952908587258, 'fraction_numerical': 0.017543859649122806, 'mean_word_length': 2.529315960912052, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 37, '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': '126286', 'n_tokens_mistral': 698, 'n_tokens_neox': 664, 'n_words': 100}