<?php
/**
 * @copyright  2009-2011 Roberto Perpuly
 *
 * This source may not be redistributed without prior consent.  Access to the 
 * source does not imply that you have consent to redistribute either this source
 * code or the generated binary. See LICENSE file for details.
 */
require_once __DIR__ . '/../lib/opportunity/array.php';

class ArrayTest extends PHPUnit_Framework_TestCase {

	function testAppendWithMultipleItems() {
		$dest = array('one', 'two', 'three');
		$src = array('four', 'five', 'six');
		\oparray\append($dest, $src);
		$expected = array('one', 'two', 'three', 'four', 'five', 'six');
		$this->assertEquals($expected, $dest);
	}
	
	function testAppendWithNoItems() {
		$dest = array('one', 'two', 'three');
		$src = NULL;
		\oparray\append($dest, $src);
		$expected = array('one', 'two', 'three');
		$this->assertEquals($expected, $dest);
	}

}