<commit_before><commit_msg>adding tests for Report class<commit_after><?php

namespace Expose;

class ReportTest extends \PHPUnit_Framework_TestCase
{
    private $report = null;

    public function setUp()
    {
        $this->report = new \Expose\Report();
    }

    /**
     * Test the getter/setter for the variable name
     * 
     * @covers \Expose\Report::getVarName
     * @covers \Expose\Report::setVarName
     */
    public function testGetSetVariableName()
    {
        $name = 'var1';
        $this->report->setVarName($name);
        $this->assertEquals(
            $this->report->getVarName(),
            $name
        );
    }

    /**
     * Test the getter/setter for the variable value
     * 
     * @covers \Expose\Report::setVarValue
     * @covers \Expose\Report::getVarValue
     */
    public function testGetSetVariableValue()
    {
        $value = 'value1';
        $this->report->setVarValue($value);
        $this->assertEquals(
            $this->report->getVarValue(),
            $value
        );
    }

    /**
     * Test the getter/setter for working with filter matches
     * 
     * @covers \Expose\Report::addFilterMatch
     * @covers \Expose\Report::getfilterMatch
     */
    public function testGetSetFilterMatch()
    {
        $matches = array('match1', 'match2');
        $this->report->addFilterMatch($matches);
        $this->assertEquals(
            $matches,
            $this->report->getFilterMatch()
        );
    }
}
{'fraction_non_alphanumeric': 0.12972972972972974, 'fraction_numerical': 0.002702702702702703, 'mean_word_length': 2.0726141078838176, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 19, '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': '2090358', 'n_tokens_mistral': 441, 'n_tokens_neox': 434, 'n_words': 82}