<commit_before><?php
/**
 * DboOracleTest file
 *
 * PHP 5
 *
 * CakePHP(tm) : Rapid Development Framework (http://cakephp.org)
 * Copyright 2005-2010, Cake Software Foundation, Inc. (http://cakefoundation.org)
 *
 * Licensed under The MIT License
 * Redistributions of files must retain the above copyright notice.
 *
 * @copyright     Copyright 2005-2010, Cake Software Foundation, Inc. (http://cakefoundation.org)
 * @link          http://cakephp.org CakePHP(tm) Project
 * @package       cake.libs
 * @since         CakePHP(tm) v 1.2.0
 * @license       MIT License (http://www.opensource.org/licenses/mit-license.php)
 */

require_once LIBS . 'model' . DS . 'datasources' . DS . 'dbo_source.php';
require_once LIBS . 'model' . DS . 'datasources' . DS . 'dbo' . DS . 'dbo_oracle.php';

/**
 * DboOracleTest class
 *
 * @package       cake.tests.cases.libs.model.datasources.dbo
 */
class DboOracleTest extends CakeTestCase {

/**
 * fixtures property
 */
	public $fixtures = array('core.oracle_user');

/**
 * setup method
 *
 * @access public
 * @return void
 */
	function setUp() {
		$this->_initDb();
	}

/**
 * skip method
 *
 * @access public
 * @return void
 */
    function skip() {
    	$this->_initDb();
    	$this->skipUnless($this->db->config['driver'] == 'oracle', '%s Oracle connection not available');
    }

/**
 * testLastErrorStatement method
 *
 * @access public
 * @return void
 */
	function testLastErrorStatement() {
		if ($this->skip('testLastErrorStatement')) {
			return;
		}

		$this->expectError();
		$this->db->execute("SELECT ' FROM dual");
		$e = $this->db->lastError();
		$r = 'ORA-01756: quoted string not properly terminated';
		$this->assertEqual($e, $r);
	}

/**
 * testLastErrorConnect method
 *
 * @access public
 * @return void
 */
	function testLastErrorConnect() {
		if ($this->skip('testLastErrorConnect')) {
			return;
		}<commit_msg>make it at least run<commit_after><?php
/**
 * DboOracleTest file
 *
 * PHP 5
 *
 * CakePHP(tm) : Rapid Development Framework (http://cakephp.org)
 * Copyright 2005-2010, Cake Software Foundation, Inc. (http://cakefoundation.org)
 *
 * Licensed under The MIT License
 * Redistributions of files must retain the above copyright notice.
 *
 * @copyright     Copyright 2005-2010, Cake Software Foundation, Inc. (http://cakefoundation.org)
 * @link          http://cakephp.org CakePHP(tm) Project
 * @package       cake.libs
 * @since         CakePHP(tm) v 1.2.0
 * @license       MIT License (http://www.opensource.org/licenses/mit-license.php)
 */

require_once LIBS . 'Model' . DS . 'Datasource' . DS . 'DboSource.php';
require_once LIBS . 'Model' . DS . 'Datasource' . DS . 'Database' . DS . 'Oracle.php';

/**
 * DboOracleTest class
 *
 * @package       cake.tests.cases.libs.model.datasources.dbo
 */
class DboOracleTest extends CakeTestCase {

/**
 * fixtures property
 */
	public $fixtures = array('core.oracle_user');

/**
 * setup method
 *
 * @access public
 * @return void
 */
	function setUp() {
		//$this->_initDb();
	}

/**
 * skip method
 *
 * @access public
 * @return void
 */
    function skip() {
    	//$this->_initDb();
    	$this->skipUnless($this->db->config['datasource'] == 'Database/Oracle', '%s Oracle connection not available');
    }

/**
 * testLastErrorStatement method
 *
 * @access public
 * @return void
 */
	function testLastErrorStatement() {
		if ($this->skip('testLastErrorStatement')) {
			return;
		}

		$this->expectError();
		$this->db->execute("SELECT ' FROM dual");
		$e = $this->db->lastError();
		$r = 'ORA-01756: quoted string not properly terminated';
		$this->assertEqual($e, $r);
	}

/**
 * testLastErrorConnect method
 *
 * @access public
 * @return void
 */
	function testLastErrorConnect() {
		if ($this->skip('testLastErrorConnect')) {
			return;
		}
{'fraction_non_alphanumeric': 0.16164021164021164, 'fraction_numerical': 0.013227513227513227, 'mean_word_length': 3.2674943566591423, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 29, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5215503', 'n_tokens_mistral': 1326, 'n_tokens_neox': 1211, 'n_words': 292}