<?php
/**
 * @package     Joomla.UnitTest
 * @subpackage  com_finder
 *
 * @copyright   Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
 * @license     GNU General Public License version 2 or later; see LICENSE
 */

require_once JPATH_ADMINISTRATOR . '/components/com_finder/helpers/indexer/helper.php';

/**
 * Test class for FinderIndexerHelper.
 * Generated by PHPUnit on 2012-06-10 at 14:41:01.
 */
class FinderIndexerHelperTest extends PHPUnit_Framework_TestCase
{
	/**
	 * @var FinderIndexerHelper
	 */
	protected $object;

	/**
	 * Sets up the fixture, for example, opens a network connection.
	 * This method is called before a test is executed.
	 */
	protected function setUp()
	{
		$this->object = new FinderIndexerHelper;
	}

	/**
	 * Tears down the fixture, for example, closes a network connection.
	 * This method is called after a test is executed.
	 */
	protected function tearDown()
	{
	}

	/**
	 * Tests the parse method
	 *
	 * @return  void
	 *
	 * @since   3.0
	 */
	public function testParse()
	{
		$this->assertThat(
			FinderIndexerHelper::parse('Test string to parse with the txt parser', 'txt'),
			$this->stringContains('Test string to parse with the txt parser'),
			'Tests that FinderIndexerHelper::parse() returns the string given with the txt parser.'
		);
	}

	/**
	 * @todo   Implement testTokenize().
	 */
	public function testTokenize()
	{
		// Remove the following lines when you implement this test.
		$this->markTestIncomplete('This test has not been implemented yet.'
		);
	}

	/**
	 * @todo   Implement testStem().
	 */
	public function testStem()
	{
		// Remove the following lines when you implement this test.
		$this->markTestIncomplete('This test has not been implemented yet.');
	}

	/**
	 * @todo   Implement testAddContentType().
	 */
	public function testAddContentType()
	{
		// Remove the following lines when you implement this test.
		$this->markTestIncomplete('This test has not been implemented yet.');
	}

	/**
	 * @todo   Implement testIsCommon().
	 */
	public function testIsCommon()
	{
		// Remove the following lines when you implement this test.
		$this->markTestIncomplete('This test has not been implemented yet.');
	}

	/**
	 * @todo   Implement testGetCommonWords().
	 */
	public function testGetCommonWords()
	{
		// Remove the following lines when you implement this test.
		$this->markTestIncomplete('This test has not been implemented yet.');
	}

	/**
	 * @todo   Implement testGetDefaultLanguage().
	 */
	public function testGetDefaultLanguage()
	{
		// Remove the following lines when you implement this test.
		$this->markTestIncomplete('This test has not been implemented yet.');
	}

	/**
	 * Tests the getPrimaryLanguage method
	 *
	 * @return  void
	 *
	 * @since   3.0
	 */
	public function testGetPrimaryLanguage()
	{
		$this->assertThat(
			FinderIndexerHelper::getPrimaryLanguage('en-GB'),
			$this->StringContains('en'),
			'The primary language is en'
		);
	}

	/**
	 * @todo   Implement testGetContentPath().
	 */
	public function testGetContentPath()
	{
		// Remove the following lines when you implement this test.
		$this->markTestIncomplete('This test has not been implemented yet.');
	}

	/**
	 * @todo   Implement testGetContentExtras().
	 */
	public function testGetContentExtras()
	{
		// Remove the following lines when you implement this test.
		$this->markTestIncomplete('This test has not been implemented yet.');
	}

	/**
	 * @todo   Implement testPrepareContent().
	 */
	public function testPrepareContent()
	{
		// Remove the following lines when you implement this test.
		$this->markTestIncomplete('This test has not been implemented yet.');
	}
}
