Skip to content

Commit 328a07d

Browse files
committed
Update OCI8 tests for oci8.old_oci_close_semantics deprecation
1 parent cd0cd3d commit 328a07d

17 files changed

+44
-27
lines changed

ext/oci8/package.xml

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,12 +53,12 @@ Oracle's standard cross-version connectivity applies. For example, PHP OCI8 lin
5353
<active>no</active>
5454
</lead>
5555

56-
<date>2020-12-21</date>
56+
<date>2021-08-02</date>
5757
<time>12:00:00</time>
5858

5959
<version>
60-
<release>3.0.1</release>
61-
<api>3.0.1</api>
60+
<release>3.1.0</release>
61+
<api>3.1.0</api>
6262
</version>
6363
<stability>
6464
<release>stable</release>
@@ -68,7 +68,7 @@ Oracle's standard cross-version connectivity applies. For example, PHP OCI8 lin
6868
<notes>
6969
This version is for PHP 8 only.
7070

71-
Updated Windows build environment to build with newer Oracle Client libraries. (cmb)
71+
Deprecated directive oci8.old_oci_close_semantics
7272
</notes>
7373
<contents>
7474
<dir name="/">
@@ -456,6 +456,23 @@ Oracle's standard cross-version connectivity applies. For example, PHP OCI8 lin
456456
</extsrcrelease>
457457
<changelog>
458458

459+
<release>
460+
<version>
461+
<release>3.0.1</release>
462+
<api>3.0.1</api>
463+
</version>
464+
<stability>
465+
<release>stable</release>
466+
<api>stable</api>
467+
</stability>
468+
<license uri="http://www.php.net/license">PHP</license>
469+
<notes>
470+
This version is for PHP 8 only.
471+
472+
Updated Windows build environment to build with newer Oracle Client libraries. (cmb)
473+
</notes>
474+
</release>
475+
459476
<release>
460477
<version>
461478
<release>2.2.0</release>

ext/oci8/php_oci8.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
*/
4242
#undef PHP_OCI8_VERSION
4343
#endif
44-
#define PHP_OCI8_VERSION "3.0.1"
44+
#define PHP_OCI8_VERSION "3.1.0"
4545

4646
extern zend_module_entry oci8_module_entry;
4747
#define phpext_oci8_ptr &oci8_module_entry

ext/oci8/tests/connect_scope_try2.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ echo "Done\n";
7676

7777
?>
7878
--EXPECTF--
79-
Directive oci8.old_oci_close_semantics is deprecated
79+
Deprecated: Directive oci8.old_oci_close_semantics is deprecated%s
8080
Test 1
8181
Caught Exception: oci_execute(): ORA-%r(00984|57000: TT2957)%r: %s
8282
resource(%d) of type (oci8 connection)

ext/oci8/tests/connect_scope_try4.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ echo "Done\n";
7676

7777
?>
7878
--EXPECTF--
79-
Directive oci8.old_oci_close_semantics is deprecated
79+
Deprecated: Directive oci8.old_oci_close_semantics is deprecated%s
8080
Test 1
8181
Caught Exception: oci_execute(): ORA-%r(00984|57000: TT2957)%r: %s
8282
resource(%d) of type (oci8 connection)

ext/oci8/tests/connect_scope_try6.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ echo "Done\n";
7676

7777
?>
7878
--EXPECTF--
79-
Directive oci8.old_oci_close_semantics is deprecated
79+
Deprecated: Directive oci8.old_oci_close_semantics is deprecated%s
8080
Test 1
8181
Caught Exception: oci_execute(): ORA-%r(00984|57000: TT2957)%r: %s
8282
resource(%d) of type (oci8 persistent connection)

ext/oci8/tests/dbmsoutput.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ function getdbmsoutput_do($c)
6464
$s = oci_parse($c, "begin dbms_output.get_line(:ln, :st); end;");
6565
oci_bind_by_name($s, ":ln", $ln, 100);
6666
oci_bind_by_name($s, ":st", $st, -1, SQLT_INT);
67-
$res = false;
67+
$res = [];
6868
while (($succ = oci_execute($s)) && !$st) {
6969
$res[] = $ln; // append each line to the array
7070
}
@@ -93,7 +93,7 @@ function getdbmsoutput_pl($c)
9393
{
9494
$s = oci_parse($c, "select * from table(mydofetch())");
9595
oci_execute($s);
96-
$res = false;
96+
$res = [];
9797
while ($row = oci_fetch_array($s, OCI_NUM)) {
9898
$res[] = $row[0];
9999
}

ext/oci8/tests/drcp_conn_close1.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ echo "Done\n";
3838

3939
?>
4040
--EXPECTF--
41-
Directive oci8.old_oci_close_semantics is deprecated
41+
Deprecated: Directive oci8.old_oci_close_semantics is deprecated%s
4242
This is with a OCI_CONNECT
4343
resource(%d) of type (oci8 connection)
4444
resource(%d) of type (oci8 connection)

ext/oci8/tests/drcp_pconn_close1.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ echo "Done\n";
3737

3838
?>
3939
--EXPECTF--
40-
Directive oci8.old_oci_close_semantics is deprecated
40+
Deprecated: Directive oci8.old_oci_close_semantics is deprecated%s
4141
This is with a OCI_PCONNECT
4242
resource(%d) of type (oci8 persistent connection)
4343
resource(%d) of type (oci8 persistent connection)

ext/oci8/tests/drcp_scope1.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ echo "Done\n";
7777

7878
?>
7979
--EXPECTF--
80-
Directive oci8.old_oci_close_semantics is deprecated
80+
Deprecated: Directive oci8.old_oci_close_semantics is deprecated%s
8181
This is with a OCI_NEW_CONNECT
8282
resource(%d) of type (oci8 connection)
8383
Update done-- DEPT value has been set to NEWDEPT

ext/oci8/tests/drcp_scope3.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ echo "Done\n";
5151

5252
?>
5353
--EXPECTF--
54-
Directive oci8.old_oci_close_semantics is deprecated
54+
Deprecated: Directive oci8.old_oci_close_semantics is deprecated%s
5555
This is with a OCI_PCONNECT
5656
resource(%d) of type (oci8 persistent connection)
5757
Update done-- DEPT value has been set to NEWDEPT

ext/oci8/tests/drcp_scope5.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ echo "Done\n";
5555

5656
?>
5757
--EXPECTF--
58-
Directive oci8.old_oci_close_semantics is deprecated
58+
Deprecated: Directive oci8.old_oci_close_semantics is deprecated%s
5959
This is with a OCI_PCONNECT
6060
resource(%d) of type (oci8 persistent connection)
6161
Update done-- DEPT value has been set to NEWDEPT

ext/oci8/tests/driver_name.phpt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,11 +57,11 @@ function get_attr($conn)
5757
?>
5858
--EXPECT--
5959
**Test 1.1 - Default values for the attribute **************
60-
The value of DRIVER_NAME is PHP OCI8 : 3.0.1
60+
The value of DRIVER_NAME is PHP OCI8 : 3.1.0
6161

6262
***Test 1.2 - Get the values from different connections **************
6363
Testing with oci_pconnect()
64-
The value of DRIVER_NAME is PHP OCI8 : 3.0.1
64+
The value of DRIVER_NAME is PHP OCI8 : 3.1.0
6565
Testing with oci_new_connect()
66-
The value of DRIVER_NAME is PHP OCI8 : 3.0.1
66+
The value of DRIVER_NAME is PHP OCI8 : 3.1.0
6767
Done

ext/oci8/tests/imp_res_dbmsoutput.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ function getdbmsoutput_do($c)
6060
$s = oci_parse($c, "begin dbms_output.get_line(:ln, :st); end;");
6161
oci_bind_by_name($s, ":ln", $ln, 100);
6262
oci_bind_by_name($s, ":st", $st, -1, SQLT_INT);
63-
$res = false;
63+
$res = [];
6464
while (($succ = oci_execute($s)) && !$st) {
6565
$res[] = $ln; // append each line to the array
6666
}

ext/oci8/tests/imp_res_get_dbmsoutput.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ function getdbmsoutput_do($c)
6464
$s = oci_parse($c, "begin dbms_output.get_line(:ln, :st); end;");
6565
oci_bind_by_name($s, ":ln", $ln, 100);
6666
oci_bind_by_name($s, ":st", $st, -1, SQLT_INT);
67-
$res = false;
67+
$res = [];
6868
while (($succ = oci_execute($s)) && !$st) {
6969
$res[] = $ln; // append each line to the array
7070
}

ext/oci8/tests/ini_1.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ var_dump(ini_set('oci8.old_oci_close_semantics', 'Off'));
5454
echo 'oci8.old_oci_close_semantics = ' . ini_get('oci8.old_oci_close_semantics') . "\n";
5555

5656
?>
57-
--EXPECT--
58-
Directive oci8.old_oci_close_semantics is deprecated
57+
--EXPECTF--
58+
Deprecated: Directive oci8.old_oci_close_semantics is deprecated%s
5959
Test 1 - check initialization
6060
oci8.privileged_connect = 1
6161
oci8.max_persistent = 111

ext/oci8/tests/lob_020.phpt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ object(OCILob)#%d (1) {
111111
["descriptor"]=>
112112
resource(%d) of type (oci8 descriptor)
113113
}
114-
int(77)
114+
int(82)
115115
int(20)
116116
array(2) {
117117
[0]=>
@@ -125,9 +125,9 @@ array(2) {
125125
resource(%d) of type (oci8 descriptor)
126126
}
127127
}
128-
string(2) "%0%0"
129-
string(5) "%0%0%0th"
130-
string(50) "is st string. why are you read"
128+
string(2) "%s"
129+
string(5) "%s"
130+
string(50) "%s at test string. why are you"
131131

132132
Warning: OCILob::erase(): ORA-22990: %s in %s on line %d
133133
bool(false)

ext/oci8/tests/old_oci_close.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ echo "Done\n";
1717

1818
?>
1919
--EXPECTF--
20-
Directive oci8.old_oci_close_semantics is deprecated
20+
Deprecated: Directive oci8.old_oci_close_semantics is deprecated%s
2121
resource(%d) of type (oci8 connection)
2222
NULL
2323
resource(%d) of type (oci8 statement)

0 commit comments

Comments
 (0)