summaryrefslogtreecommitdiff
path: root/ext/pgsql/tests
Commit message (Collapse)AuthorAgeFilesLines
* Add --repeat testing modeNikita Popov2020-10-301-0/+5
| | | | | | | | | This testing mode executes the test multiple times in the same process (but in different requests). It is primarily intended to catch tracing JIT bugs, but also catches state leaks across requests. Closes GH-6365.
* Update ext/pgsql parameter namesNikita Popov2020-10-134-12/+12
| | | | Closes GH-6294.
* Promote E_NOTICE to Value/TypeError in PostgreSQL extensionGeorge Peter Banyard2020-09-295-0/+175
| | | | | | | | | Add some tests to cover related codepaths. With the small caveat that the ones in build_assignment_string() still don't seem to be tested as it looks the condtions are checked beforehand, might need some more investigation. Closes GH-6226
* Return empty array for no rows in pg_fetch_all()Nikita Popov2020-09-211-0/+3
| | | | | This makes it line up with pg_fetch_all_columns(), as well as similar functions in other exts, such as mysqli_fetch_all().
* Promote invalid field to ValueError in pgsqlNikita Popov2020-09-211-0/+74
| | | | | | | | The same error condition is a ValueError in mysqli, be consistent. Additionally, do not display the argument name for these errors. As the signatures are overloaded, the argument name may not match the meaning at all.
* Deprecate pgsql function aliasesNikita Popov2020-09-212-2/+25
| | | | | These have been documentation-deprecated for a very long time, make it official.
* Promote warnings to Errors in PostgreSQL extensionGeorge Peter Banyard2020-09-144-23/+48
| | | | | | | Do some drive by indentation fixes Also fix pg_select() in regards to the $result_type arg which was missing from ZPP Closes GH-6129
* Remove deprecated pgsql signaturesNikita Popov2020-09-091-1/+1
| | | | As the comment indicates, these are deprecated in PHP 4.2...
* Promote pgsql no link to Error exceptionNikita Popov2020-09-091-0/+14
|
* Remove deprecated multi-parameter form of pg_connect()Nikita Popov2020-09-091-9/+8
|
* Use zpp C in pg_fetch_objectNikita Popov2020-08-131-0/+7
|
* Add many missing closing PHP tags to testsMáté Kocsis2020-08-091-0/+1
| | | | Closes GH-5958
* Reindent phpt filesNikita Popov2020-02-0335-457/+457
|
* Fix #78880: Spelling error reportChristoph M. Becker2019-12-211-2/+2
| | | | | | | We fix the most often occuring typos according to a recent codespell report[1] in tests, code comments and documentation. [1] <https://fossies.org/linux/test/php-src-master-f8f48ce.191129.tar.gz/codespell.html>.
* Clean DONE tags from testsFabien Villepinte2019-11-0710-20/+0
| | | | | | | Remove most of the `===DONE===` tags and its variations. Keep `===DONE===` if the test output otherwise becomes empty. Closes GH-4872.
* Merge branch 'PHP-7.4'Nikita Popov2019-06-042-4/+4
|\
| * Try to make 17result.php more robustNikita Popov2019-06-042-4/+4
| | | | | | | | | | | | This is our most common intermittent failure. I don't understand why it happens and can't reproduce it, but defining an explicit sort order seems worth a shot...
* | Convert fetch_resource warnings into TypeErrorsNikita Popov2019-06-031-2/+6
| | | | | | | | | | More type checks that are not part of zpp and should generate a TypeError in PHP 8.
* | Merge branch 'PHP-7.4'Peter Kokot2019-05-122-16/+18
|\ \ | |/ | | | | | | * PHP-7.4: [ci skip] Migrate tests READMEs to Markdown
| * [ci skip] Migrate tests READMEs to MarkdownPeter Kokot2019-05-122-16/+18
| |
* | Merge branch 'PHP-7.4'Nikita Popov2019-04-101-3/+5
|\ \ | |/
| * Merge branch 'PHP-7.3' into PHP-7.4Nikita Popov2019-04-101-3/+5
| |\
| | * Merge branch 'PHP-7.2' into PHP-7.3Nikita Popov2019-04-101-3/+5
| | |\
| | | * Fix 29nb_async_connect.phptNikita Popov2019-04-101-3/+5
| | | | | | | | | | | | | | | | | | | | Intermediate states are unreliable across versions (I think), make sure we go through the whole connect procedure.
* | | | Merge branch 'PHP-7.4'Nikita Popov2019-04-101-0/+19
|\ \ \ \ | |/ / /
| * | | Merge branch 'PHP-7.3' into PHP-7.4Nikita Popov2019-04-101-0/+19
| |\ \ \ | | |/ /
| | * | Merge branch 'PHP-7.2' into PHP-7.3Nikita Popov2019-04-101-0/+19
| | |\ \ | | | |/
| | | * Fix pgsql use after free trying to reuse closed connectionNikita Popov2019-04-101-0/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a connection is closed, we also need to remove the hash entry from the regular_list, as it now points to freed memory. To do this store a reverse mapping from the connection to the hash string. It would be nicer to introduce a wrapping structure for the pgsql link resource that could store the hash (and notices), but that would require large changes to the extension, so I'm going for a more minimal fix here.
* | | | Merge branch 'PHP-7.4'Nikita Popov2019-04-101-0/+15
|\ \ \ \ | |/ / /
| * | | Merge branch 'PHP-7.3' into PHP-7.4Nikita Popov2019-04-101-0/+15
| |\ \ \ | | |/ /
| | * | Merge branch 'PHP-7.2' into PHP-7.3Nikita Popov2019-04-101-0/+15
| | |\ \ | | | |/
| | | * Fix use after free on pg_close() of default connectionNikita Popov2019-04-101-0/+15
| | | |
| | | * Fixed bug #77047 pg_convert has a broken regex for the 'TIME WITHOUT ↵Anatol Belski2018-11-181-0/+40
| | | | | | | | | | | | | | | | | | | | | | | | TIMEZONE' data type Backport 369c991d and 282a63da to 7.1, closes #3634
| | | * Sync leading and final newlines in *.phpt sectionsPeter Kokot2018-10-1513-14/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds missing newlines, trims multiple redundant final newlines into a single one, and trims redundant leading newlines in all *.phpt sections. According to POSIX, a line is a sequence of zero or more non-' <newline>' characters plus a terminating '<newline>' character. [1] Files should normally have at least one final newline character. C89 [2] and later standards [3] mention a final newline: "A source file that is not empty shall end in a new-line character, which shall not be immediately preceded by a backslash character." Although it is not mandatory for all files to have a final newline fixed, a more consistent and homogeneous approach brings less of commit differences issues and a better development experience in certain text editors and IDEs. [1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206 [2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2 [3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
| | | * Trim trailing whitespace in *.phptPeter Kokot2018-10-1420-67/+67
| | | |
| | | * Sync leading and final newlines in source code filesPeter Kokot2018-10-141-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds missing newlines, trims multiple redundant final newlines into a single one, and trims redundant leading newlines. According to POSIX, a line is a sequence of zero or more non-' <newline>' characters plus a terminating '<newline>' character. [1] Files should normally have at least one final newline character. C89 [2] and later standards [3] mention a final newline: "A source file that is not empty shall end in a new-line character, which shall not be immediately preceded by a backslash character." Although it is not mandatory for all files to have a final newline fixed, a more consistent and homogeneous approach brings less of commit differences issues and a better development experience in certain text editors and IDEs. [1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206 [2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2 [3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
| | | * Trim trailing whitespace in source code filesPeter Kokot2018-10-131-6/+6
| | | |
| | | * Convert CRLF line endings to LFPeter Kokot2018-10-131-78/+78
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch simplifies line endings tracked in the Git repository and syncs them to all include the LF style instead of the CRLF files. Newline characters: - LF (\n) (*nix and Mac) - CRLF (\r\n) (Windows) - CR (\r) (old Mac, obsolete) To see which line endings are in the index and in the working copy the following command can be used: `git ls-files --eol` Git additionally provides `.gitattributes` file to specify if some files need to have specific line endings on all platforms (either CRLF or LF). Changed files shouldn't cause issues on modern Windows platforms because also Git can do output conversion is core.autocrlf=true is set on Windows and use CRLF newlines in all files in the working tree. Unless CRLF files are tracked specifically, Git by default tracks all files in the index using LF newlines.
* | | | Merge branch 'PHP-7.4'Peter Kokot2019-03-158-11/+11
|\ \ \ \ | |/ / / | | | | | | | | | | | | * PHP-7.4: Replace dirname(__FILE__) by __DIR__ in tests
| * | | Replace dirname(__FILE__) by __DIR__ in testsFabien Villepinte2019-03-158-11/+11
| | | |
* | | | Adjust tests for zpp TypeError changeNikita Popov2019-03-111-2/+2
|/ / /
* | | Use EXPECT when possibleGabriel Caruso2019-03-111-1/+1
| | | | | | | | | | | | EXPECTF logic in run-tests.php is considerable, so let's avoid it.
* | | Implement fine-grained conflict handlingNikita Popov2019-02-201-0/+1
| | | | | | | | | | | | | | | | | | Tests can specify conflict keys, either in --CONFLICTS-- or a per-directory CONFLICTS file. Non-conflicting tests may be run in parallel.
* | | Fix typo in testsFabien Villepinte2018-11-192-2/+2
| | |
* | | Merge branch 'PHP-7.3'Anatol Belski2018-11-181-0/+40
|\ \ \ | |/ / | | | | | | | | | | | | * PHP-7.3: Add test for bug #77047 FIX #77047: fixes regex for "time" data type
| * | Add test for bug #77047Anatol Belski2018-11-181-0/+40
| | |
| * | Sync leading and final newlines in *.phpt sectionsPeter Kokot2018-10-1513-14/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds missing newlines, trims multiple redundant final newlines into a single one, and trims redundant leading newlines in all *.phpt sections. According to POSIX, a line is a sequence of zero or more non-' <newline>' characters plus a terminating '<newline>' character. [1] Files should normally have at least one final newline character. C89 [2] and later standards [3] mention a final newline: "A source file that is not empty shall end in a new-line character, which shall not be immediately preceded by a backslash character." Although it is not mandatory for all files to have a final newline fixed, a more consistent and homogeneous approach brings less of commit differences issues and a better development experience in certain text editors and IDEs. [1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206 [2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2 [3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
| * | Trim trailing whitespace in *.phptPeter Kokot2018-10-1420-67/+67
| | |
| * | Sync leading and final newlines in source code filesPeter Kokot2018-10-141-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds missing newlines, trims multiple redundant final newlines into a single one, and trims redundant leading newlines. According to POSIX, a line is a sequence of zero or more non-' <newline>' characters plus a terminating '<newline>' character. [1] Files should normally have at least one final newline character. C89 [2] and later standards [3] mention a final newline: "A source file that is not empty shall end in a new-line character, which shall not be immediately preceded by a backslash character." Although it is not mandatory for all files to have a final newline fixed, a more consistent and homogeneous approach brings less of commit differences issues and a better development experience in certain text editors and IDEs. [1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206 [2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2 [3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
| * | Trim trailing whitespace in source code filesPeter Kokot2018-10-131-6/+6
| | |