sixd Fri, 10 Jun 2011 17:38:07 +0000 Revision: http://svn.php.net/viewvc?view=revision&revision=312017
Log: Add oci_client_version() returning the runtime Oracle client library version - predominantly useful for the test suite Changed paths: U php/php-src/branches/PHP_5_3/NEWS U php/php-src/branches/PHP_5_3/ext/oci8/oci8.c U php/php-src/branches/PHP_5_3/ext/oci8/oci8_interface.c U php/php-src/branches/PHP_5_3/ext/oci8/php_oci8_int.h A php/php-src/branches/PHP_5_3/ext/oci8/tests/clientversion.phpt A php/php-src/branches/PHP_5_3/ext/oci8/tests/clientversion_92.phpt U php/php-src/branches/PHP_5_4/ext/oci8/oci8.c U php/php-src/branches/PHP_5_4/ext/oci8/oci8_interface.c U php/php-src/branches/PHP_5_4/ext/oci8/php_oci8_int.h A php/php-src/branches/PHP_5_4/ext/oci8/tests/clientversion.phpt A php/php-src/branches/PHP_5_4/ext/oci8/tests/clientversion_92.phpt U php/php-src/trunk/ext/oci8/oci8.c U php/php-src/trunk/ext/oci8/oci8_interface.c U php/php-src/trunk/ext/oci8/php_oci8_int.h A php/php-src/trunk/ext/oci8/tests/clientversion.phpt A php/php-src/trunk/ext/oci8/tests/clientversion_92.phpt
Modified: php/php-src/branches/PHP_5_3/NEWS =================================================================== --- php/php-src/branches/PHP_5_3/NEWS 2011-06-10 17:16:00 UTC (rev 312016) +++ php/php-src/branches/PHP_5_3/NEWS 2011-06-10 17:38:07 UTC (rev 312017) @@ -125,6 +125,10 @@ . Fixed bug #54992 (Stream not closed and error not returned when SSL CN_match fails). (Gustavo, laird_ngrps at dodo dot com dot au) +- Oracle Database extension (OCI8): + . Added oci_client_version() returning the runtime Oracle client library + version (Chris Jones) + - PDO extension: . Fixed bug #54929 (Parse error with single quote in sql comment). (Felipe) . Fixed bug #52104 (bindColumn creates Warning regardless of ATTR_ERRMODE Modified: php/php-src/branches/PHP_5_3/ext/oci8/oci8.c =================================================================== --- php/php-src/branches/PHP_5_3/ext/oci8/oci8.c 2011-06-10 17:16:00 UTC (rev 312016) +++ php/php-src/branches/PHP_5_3/ext/oci8/oci8.c 2011-06-10 17:38:07 UTC (rev 312017) @@ -447,6 +447,9 @@ ZEND_ARG_INFO(0, column_number_or_name) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO(arginfo_oci_client_version, 0) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_oci_server_version, 0, 0, 1) ZEND_ARG_INFO(0, connection_resource) ZEND_END_ARG_INFO() @@ -681,6 +684,7 @@ #define arginfo_oci_password_change NULL #define arginfo_oci_new_cursor NULL #define arginfo_oci_result NULL +#define arginfo_oci_client_version NULL #define arginfo_oci_server_version NULL #define arginfo_oci_statement_type NULL #define arginfo_oci_num_rows NULL @@ -761,6 +765,7 @@ PHP_FUNCTION(oci_parse); PHP_FUNCTION(oci_new_cursor); PHP_FUNCTION(oci_result); +PHP_FUNCTION(oci_client_version); PHP_FUNCTION(oci_server_version); PHP_FUNCTION(oci_statement_type); PHP_FUNCTION(oci_num_rows); @@ -836,6 +841,7 @@ PHP_FE(oci_parse, arginfo_oci_parse) PHP_FE(oci_new_cursor, arginfo_oci_new_cursor) PHP_FE(oci_result, arginfo_oci_result) + PHP_FE(oci_client_version, arginfo_oci_client_version) PHP_FE(oci_server_version, arginfo_oci_server_version) PHP_FE(oci_statement_type, arginfo_oci_statement_type) PHP_FE(oci_num_rows, arginfo_oci_num_rows) @@ -1295,6 +1301,7 @@ PHP_MINFO_FUNCTION(oci) { char buf[32]; + char *ver; php_info_print_table_start(); php_info_print_table_row(2, "OCI8 Support", "enabled"); @@ -1306,6 +1313,11 @@ snprintf(buf, sizeof(buf), "%ld", OCI_G(num_links)); php_info_print_table_row(2, "Active Connections", buf); +#if ((OCI_MAJOR_VERSION > 10) || ((OCI_MAJOR_VERSION == 10) && (OCI_MINOR_VERSION >= 2))) + php_oci_client_get_version(&ver TSRMLS_DC); + php_info_print_table_row(2, "Oracle Run-time Client Library Version", ver); + efree(ver); +#endif #if defined(OCI_MAJOR_VERSION) && defined(OCI_MINOR_VERSION) snprintf(buf, sizeof(buf), "%d.%d", OCI_MAJOR_VERSION, OCI_MINOR_VERSION); #elif defined(PHP_OCI8_ORACLE_VERSION) @@ -2384,6 +2396,30 @@ return 0; } /* }}} */ + +/* {{{ php_oci_client_get_version() + * + * Get Oracle client library version + */ +void php_oci_client_get_version(char **version TSRMLS_DC) +{ + char version_buff[256]; + sword major_version = 0; + sword minor_version = 0; + sword update_num = 0; + sword patch_num = 0; + sword port_update_num = 0; + +#if ((OCI_MAJOR_VERSION > 10) || ((OCI_MAJOR_VERSION == 10) && (OCI_MINOR_VERSION >= 2))) /* OCIClientVersion only available 10.2 onwards */ + PHP_OCI_CALL(OCIClientVersion, (&major_version, &minor_version, &update_num, &patch_num, &port_update_num)); + snprintf(version_buff, sizeof(version_buff), "%d.%d.%d.%d.%d", major_version, minor_version, update_num, patch_num, port_update_num); +#else + memcpy(version_buff, "Unknown", sizeof("Unknown")); +#endif + *version = estrdup(version_buff); +} /* }}} */ + + /* {{{ php_oci_server_get_version() * * Get Oracle server version Modified: php/php-src/branches/PHP_5_3/ext/oci8/oci8_interface.c =================================================================== --- php/php-src/branches/PHP_5_3/ext/oci8/oci8_interface.c 2011-06-10 17:16:00 UTC (rev 312016) +++ php/php-src/branches/PHP_5_3/ext/oci8/oci8_interface.c 2011-06-10 17:38:07 UTC (rev 312017) @@ -2002,6 +2002,17 @@ } /* }}} */ +/* {{{ proto string oci_client_version() + Return a string containing runtime client library version information */ +PHP_FUNCTION(oci_client_version) +{ + char *version = NULL; + + php_oci_client_get_version(&version TSRMLS_CC); + RETURN_STRING(version, 0); +} +/* }}} */ + /* {{{ proto string oci_server_version(resource connection) Return a string containing server version information */ PHP_FUNCTION(oci_server_version) Modified: php/php-src/branches/PHP_5_3/ext/oci8/php_oci8_int.h =================================================================== --- php/php-src/branches/PHP_5_3/ext/oci8/php_oci8_int.h 2011-06-10 17:16:00 UTC (rev 312016) +++ php/php-src/branches/PHP_5_3/ext/oci8/php_oci8_int.h 2011-06-10 17:38:07 UTC (rev 312017) @@ -385,6 +385,7 @@ int php_oci_connection_release(php_oci_connection *connection TSRMLS_DC); int php_oci_password_change(php_oci_connection *, char *, int, char *, int, char *, int TSRMLS_DC); +void php_oci_client_get_version(char ** TSRMLS_DC); int php_oci_server_get_version(php_oci_connection *, char ** TSRMLS_DC); void php_oci_fetch_row(INTERNAL_FUNCTION_PARAMETERS, int, int); Added: php/php-src/branches/PHP_5_3/ext/oci8/tests/clientversion.phpt =================================================================== --- php/php-src/branches/PHP_5_3/ext/oci8/tests/clientversion.phpt (rev 0) +++ php/php-src/branches/PHP_5_3/ext/oci8/tests/clientversion.phpt 2011-06-10 17:38:07 UTC (rev 312017) @@ -0,0 +1,20 @@ +--TEST-- +oci_client_version() +--SKIPIF-- +<?php +if (!extension_loaded('oci8')) die("skip no oci8 extension"); +if (preg_match('/^1[012]\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 10g or greater version of client"); +} +?> +--FILE-- +<?php + +echo oci_client_version(), "\n"; + +?> +===DONE=== +<?php exit(0); ?> +--EXPECTF-- +%d.%d.%d.%d.%d +===DONE=== Property changes on: php/php-src/branches/PHP_5_3/ext/oci8/tests/clientversion.phpt ___________________________________________________________________ Added: svn:keywords + Id Rev Revision Added: svn:eol-style + native Added: php/php-src/branches/PHP_5_3/ext/oci8/tests/clientversion_92.phpt =================================================================== --- php/php-src/branches/PHP_5_3/ext/oci8/tests/clientversion_92.phpt (rev 0) +++ php/php-src/branches/PHP_5_3/ext/oci8/tests/clientversion_92.phpt 2011-06-10 17:38:07 UTC (rev 312017) @@ -0,0 +1,20 @@ +--TEST-- +oci_client_version() for Oracle 9.2 client libraries +--SKIPIF-- +<?php +if (!extension_loaded('oci8')) die("skip no oci8 extension"); +if (preg_match('/Unknown/', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 9gR2 client libraries"); +} +?> +--FILE-- +<?php + +echo oci_client_version(), "\n"; + +?> +===DONE=== +<?php exit(0); ?> +--EXPECTF-- +Unknown +===DONE=== Property changes on: php/php-src/branches/PHP_5_3/ext/oci8/tests/clientversion_92.phpt ___________________________________________________________________ Added: svn:keywords + Id Rev Revision Added: svn:eol-style + native Modified: php/php-src/branches/PHP_5_4/ext/oci8/oci8.c =================================================================== --- php/php-src/branches/PHP_5_4/ext/oci8/oci8.c 2011-06-10 17:16:00 UTC (rev 312016) +++ php/php-src/branches/PHP_5_4/ext/oci8/oci8.c 2011-06-10 17:38:07 UTC (rev 312017) @@ -447,6 +447,9 @@ ZEND_ARG_INFO(0, column_number_or_name) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO(arginfo_oci_client_version, 0) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_oci_server_version, 0, 0, 1) ZEND_ARG_INFO(0, connection_resource) ZEND_END_ARG_INFO() @@ -681,6 +684,7 @@ #define arginfo_oci_password_change NULL #define arginfo_oci_new_cursor NULL #define arginfo_oci_result NULL +#define arginfo_oci_client_version NULL #define arginfo_oci_server_version NULL #define arginfo_oci_statement_type NULL #define arginfo_oci_num_rows NULL @@ -761,6 +765,7 @@ PHP_FUNCTION(oci_parse); PHP_FUNCTION(oci_new_cursor); PHP_FUNCTION(oci_result); +PHP_FUNCTION(oci_client_version); PHP_FUNCTION(oci_server_version); PHP_FUNCTION(oci_statement_type); PHP_FUNCTION(oci_num_rows); @@ -836,6 +841,7 @@ PHP_FE(oci_parse, arginfo_oci_parse) PHP_FE(oci_new_cursor, arginfo_oci_new_cursor) PHP_FE(oci_result, arginfo_oci_result) + PHP_FE(oci_client_version, arginfo_oci_client_version) PHP_FE(oci_server_version, arginfo_oci_server_version) PHP_FE(oci_statement_type, arginfo_oci_statement_type) PHP_FE(oci_num_rows, arginfo_oci_num_rows) @@ -1295,6 +1301,7 @@ PHP_MINFO_FUNCTION(oci) { char buf[32]; + char *ver; php_info_print_table_start(); php_info_print_table_row(2, "OCI8 Support", "enabled"); @@ -1306,6 +1313,11 @@ snprintf(buf, sizeof(buf), "%ld", OCI_G(num_links)); php_info_print_table_row(2, "Active Connections", buf); +#if ((OCI_MAJOR_VERSION > 10) || ((OCI_MAJOR_VERSION == 10) && (OCI_MINOR_VERSION >= 2))) + php_oci_client_get_version(&ver TSRMLS_DC); + php_info_print_table_row(2, "Oracle Run-time Client Library Version", ver); + efree(ver); +#endif #if defined(OCI_MAJOR_VERSION) && defined(OCI_MINOR_VERSION) snprintf(buf, sizeof(buf), "%d.%d", OCI_MAJOR_VERSION, OCI_MINOR_VERSION); #elif defined(PHP_OCI8_ORACLE_VERSION) @@ -2384,6 +2396,30 @@ return 0; } /* }}} */ + +/* {{{ php_oci_client_get_version() + * + * Get Oracle client library version + */ +void php_oci_client_get_version(char **version TSRMLS_DC) +{ + char version_buff[256]; + sword major_version = 0; + sword minor_version = 0; + sword update_num = 0; + sword patch_num = 0; + sword port_update_num = 0; + +#if ((OCI_MAJOR_VERSION > 10) || ((OCI_MAJOR_VERSION == 10) && (OCI_MINOR_VERSION >= 2))) /* OCIClientVersion only available 10.2 onwards */ + PHP_OCI_CALL(OCIClientVersion, (&major_version, &minor_version, &update_num, &patch_num, &port_update_num)); + snprintf(version_buff, sizeof(version_buff), "%d.%d.%d.%d.%d", major_version, minor_version, update_num, patch_num, port_update_num); +#else + memcpy(version_buff, "Unknown", sizeof("Unknown")); +#endif + *version = estrdup(version_buff); +} /* }}} */ + + /* {{{ php_oci_server_get_version() * * Get Oracle server version Modified: php/php-src/branches/PHP_5_4/ext/oci8/oci8_interface.c =================================================================== --- php/php-src/branches/PHP_5_4/ext/oci8/oci8_interface.c 2011-06-10 17:16:00 UTC (rev 312016) +++ php/php-src/branches/PHP_5_4/ext/oci8/oci8_interface.c 2011-06-10 17:38:07 UTC (rev 312017) @@ -2002,6 +2002,17 @@ } /* }}} */ +/* {{{ proto string oci_client_version() + Return a string containing runtime client library version information */ +PHP_FUNCTION(oci_client_version) +{ + char *version = NULL; + + php_oci_client_get_version(&version TSRMLS_CC); + RETURN_STRING(version, 0); +} +/* }}} */ + /* {{{ proto string oci_server_version(resource connection) Return a string containing server version information */ PHP_FUNCTION(oci_server_version) Modified: php/php-src/branches/PHP_5_4/ext/oci8/php_oci8_int.h =================================================================== --- php/php-src/branches/PHP_5_4/ext/oci8/php_oci8_int.h 2011-06-10 17:16:00 UTC (rev 312016) +++ php/php-src/branches/PHP_5_4/ext/oci8/php_oci8_int.h 2011-06-10 17:38:07 UTC (rev 312017) @@ -385,6 +385,7 @@ int php_oci_connection_release(php_oci_connection *connection TSRMLS_DC); int php_oci_password_change(php_oci_connection *, char *, int, char *, int, char *, int TSRMLS_DC); +void php_oci_client_get_version(char ** TSRMLS_DC); int php_oci_server_get_version(php_oci_connection *, char ** TSRMLS_DC); void php_oci_fetch_row(INTERNAL_FUNCTION_PARAMETERS, int, int); Added: php/php-src/branches/PHP_5_4/ext/oci8/tests/clientversion.phpt =================================================================== --- php/php-src/branches/PHP_5_4/ext/oci8/tests/clientversion.phpt (rev 0) +++ php/php-src/branches/PHP_5_4/ext/oci8/tests/clientversion.phpt 2011-06-10 17:38:07 UTC (rev 312017) @@ -0,0 +1,20 @@ +--TEST-- +oci_client_version() +--SKIPIF-- +<?php +if (!extension_loaded('oci8')) die("skip no oci8 extension"); +if (preg_match('/^1[012]\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 10g or greater version of client"); +} +?> +--FILE-- +<?php + +echo oci_client_version(), "\n"; + +?> +===DONE=== +<?php exit(0); ?> +--EXPECTF-- +%d.%d.%d.%d.%d +===DONE=== Property changes on: php/php-src/branches/PHP_5_4/ext/oci8/tests/clientversion.phpt ___________________________________________________________________ Added: svn:keywords + Id Rev Revision Added: svn:eol-style + native Added: php/php-src/branches/PHP_5_4/ext/oci8/tests/clientversion_92.phpt =================================================================== --- php/php-src/branches/PHP_5_4/ext/oci8/tests/clientversion_92.phpt (rev 0) +++ php/php-src/branches/PHP_5_4/ext/oci8/tests/clientversion_92.phpt 2011-06-10 17:38:07 UTC (rev 312017) @@ -0,0 +1,20 @@ +--TEST-- +oci_client_version() for Oracle 9.2 client libraries +--SKIPIF-- +<?php +if (!extension_loaded('oci8')) die("skip no oci8 extension"); +if (preg_match('/Unknown/', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 9gR2 client libraries"); +} +?> +--FILE-- +<?php + +echo oci_client_version(), "\n"; + +?> +===DONE=== +<?php exit(0); ?> +--EXPECTF-- +Unknown +===DONE=== Property changes on: php/php-src/branches/PHP_5_4/ext/oci8/tests/clientversion_92.phpt ___________________________________________________________________ Added: svn:keywords + Id Rev Revision Added: svn:eol-style + native Modified: php/php-src/trunk/ext/oci8/oci8.c =================================================================== --- php/php-src/trunk/ext/oci8/oci8.c 2011-06-10 17:16:00 UTC (rev 312016) +++ php/php-src/trunk/ext/oci8/oci8.c 2011-06-10 17:38:07 UTC (rev 312017) @@ -447,6 +447,9 @@ ZEND_ARG_INFO(0, column_number_or_name) ZEND_END_ARG_INFO() +ZEND_BEGIN_ARG_INFO(arginfo_oci_client_version, 0) +ZEND_END_ARG_INFO() + ZEND_BEGIN_ARG_INFO_EX(arginfo_oci_server_version, 0, 0, 1) ZEND_ARG_INFO(0, connection_resource) ZEND_END_ARG_INFO() @@ -681,6 +684,7 @@ #define arginfo_oci_password_change NULL #define arginfo_oci_new_cursor NULL #define arginfo_oci_result NULL +#define arginfo_oci_client_version NULL #define arginfo_oci_server_version NULL #define arginfo_oci_statement_type NULL #define arginfo_oci_num_rows NULL @@ -761,6 +765,7 @@ PHP_FUNCTION(oci_parse); PHP_FUNCTION(oci_new_cursor); PHP_FUNCTION(oci_result); +PHP_FUNCTION(oci_client_version); PHP_FUNCTION(oci_server_version); PHP_FUNCTION(oci_statement_type); PHP_FUNCTION(oci_num_rows); @@ -836,6 +841,7 @@ PHP_FE(oci_parse, arginfo_oci_parse) PHP_FE(oci_new_cursor, arginfo_oci_new_cursor) PHP_FE(oci_result, arginfo_oci_result) + PHP_FE(oci_client_version, arginfo_oci_client_version) PHP_FE(oci_server_version, arginfo_oci_server_version) PHP_FE(oci_statement_type, arginfo_oci_statement_type) PHP_FE(oci_num_rows, arginfo_oci_num_rows) @@ -1295,6 +1301,7 @@ PHP_MINFO_FUNCTION(oci) { char buf[32]; + char *ver; php_info_print_table_start(); php_info_print_table_row(2, "OCI8 Support", "enabled"); @@ -1306,6 +1313,11 @@ snprintf(buf, sizeof(buf), "%ld", OCI_G(num_links)); php_info_print_table_row(2, "Active Connections", buf); +#if ((OCI_MAJOR_VERSION > 10) || ((OCI_MAJOR_VERSION == 10) && (OCI_MINOR_VERSION >= 2))) + php_oci_client_get_version(&ver TSRMLS_DC); + php_info_print_table_row(2, "Oracle Run-time Client Library Version", ver); + efree(ver); +#endif #if defined(OCI_MAJOR_VERSION) && defined(OCI_MINOR_VERSION) snprintf(buf, sizeof(buf), "%d.%d", OCI_MAJOR_VERSION, OCI_MINOR_VERSION); #elif defined(PHP_OCI8_ORACLE_VERSION) @@ -2384,6 +2396,30 @@ return 0; } /* }}} */ + +/* {{{ php_oci_client_get_version() + * + * Get Oracle client library version + */ +void php_oci_client_get_version(char **version TSRMLS_DC) +{ + char version_buff[256]; + sword major_version = 0; + sword minor_version = 0; + sword update_num = 0; + sword patch_num = 0; + sword port_update_num = 0; + +#if ((OCI_MAJOR_VERSION > 10) || ((OCI_MAJOR_VERSION == 10) && (OCI_MINOR_VERSION >= 2))) /* OCIClientVersion only available 10.2 onwards */ + PHP_OCI_CALL(OCIClientVersion, (&major_version, &minor_version, &update_num, &patch_num, &port_update_num)); + snprintf(version_buff, sizeof(version_buff), "%d.%d.%d.%d.%d", major_version, minor_version, update_num, patch_num, port_update_num); +#else + memcpy(version_buff, "Unknown", sizeof("Unknown")); +#endif + *version = estrdup(version_buff); +} /* }}} */ + + /* {{{ php_oci_server_get_version() * * Get Oracle server version Modified: php/php-src/trunk/ext/oci8/oci8_interface.c =================================================================== --- php/php-src/trunk/ext/oci8/oci8_interface.c 2011-06-10 17:16:00 UTC (rev 312016) +++ php/php-src/trunk/ext/oci8/oci8_interface.c 2011-06-10 17:38:07 UTC (rev 312017) @@ -2002,6 +2002,17 @@ } /* }}} */ +/* {{{ proto string oci_client_version() + Return a string containing runtime client library version information */ +PHP_FUNCTION(oci_client_version) +{ + char *version = NULL; + + php_oci_client_get_version(&version TSRMLS_CC); + RETURN_STRING(version, 0); +} +/* }}} */ + /* {{{ proto string oci_server_version(resource connection) Return a string containing server version information */ PHP_FUNCTION(oci_server_version) Modified: php/php-src/trunk/ext/oci8/php_oci8_int.h =================================================================== --- php/php-src/trunk/ext/oci8/php_oci8_int.h 2011-06-10 17:16:00 UTC (rev 312016) +++ php/php-src/trunk/ext/oci8/php_oci8_int.h 2011-06-10 17:38:07 UTC (rev 312017) @@ -385,6 +385,7 @@ int php_oci_connection_release(php_oci_connection *connection TSRMLS_DC); int php_oci_password_change(php_oci_connection *, char *, int, char *, int, char *, int TSRMLS_DC); +void php_oci_client_get_version(char ** TSRMLS_DC); int php_oci_server_get_version(php_oci_connection *, char ** TSRMLS_DC); void php_oci_fetch_row(INTERNAL_FUNCTION_PARAMETERS, int, int); Added: php/php-src/trunk/ext/oci8/tests/clientversion.phpt =================================================================== --- php/php-src/trunk/ext/oci8/tests/clientversion.phpt (rev 0) +++ php/php-src/trunk/ext/oci8/tests/clientversion.phpt 2011-06-10 17:38:07 UTC (rev 312017) @@ -0,0 +1,20 @@ +--TEST-- +oci_client_version() +--SKIPIF-- +<?php +if (!extension_loaded('oci8')) die("skip no oci8 extension"); +if (preg_match('/^1[012]\./', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 10g or greater version of client"); +} +?> +--FILE-- +<?php + +echo oci_client_version(), "\n"; + +?> +===DONE=== +<?php exit(0); ?> +--EXPECTF-- +%d.%d.%d.%d.%d +===DONE=== Property changes on: php/php-src/trunk/ext/oci8/tests/clientversion.phpt ___________________________________________________________________ Added: svn:keywords + Id Rev Revision Added: svn:eol-style + native Added: php/php-src/trunk/ext/oci8/tests/clientversion_92.phpt =================================================================== --- php/php-src/trunk/ext/oci8/tests/clientversion_92.phpt (rev 0) +++ php/php-src/trunk/ext/oci8/tests/clientversion_92.phpt 2011-06-10 17:38:07 UTC (rev 312017) @@ -0,0 +1,20 @@ +--TEST-- +oci_client_version() for Oracle 9.2 client libraries +--SKIPIF-- +<?php +if (!extension_loaded('oci8')) die("skip no oci8 extension"); +if (preg_match('/Unknown/', oci_client_version()) != 1) { + die("skip test expected to work only with Oracle 9gR2 client libraries"); +} +?> +--FILE-- +<?php + +echo oci_client_version(), "\n"; + +?> +===DONE=== +<?php exit(0); ?> +--EXPECTF-- +Unknown +===DONE=== Property changes on: php/php-src/trunk/ext/oci8/tests/clientversion_92.phpt ___________________________________________________________________ Added: svn:keywords + Id Rev Revision Added: svn:eol-style + native
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php