1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 23:58:11 +00:00
serenity/Tests
Jan de Visser 001949d77a LibSQL: Improve error handling
The handling of filesystem level errors was basically non-existing or
consisting of `VERIFY_NOT_REACHED` assertions. Addressed this by
* Adding `open` methods to `Heap` and `Database` which return errors.
* Changing the interface of methods of these classes and clients
downstream to propagate these errors.

The constructors of `Heap` and `Database` don't open the underlying
filesystem file anymore.

The SQL statement handlers return an `SQLErrorCode::InternalError`
error code if an error comes back from the lower levels. Note that some
of these errors are things like duplicate index entry errors that should
be caught before the SQL layer attempts to actually update the database.

Added tests to catch attempts to open weird or non-existent files as
databases.

Finally, in between me writing this patch and submitting the PR the
AK::Result<Foo, Bar> template got deprecated in favour of ErrorOr<Foo>.
This resulted in more busywork.
2021-12-04 20:49:22 +03:30
..
AK AK: Convert AK::Format formatting helpers to returning ErrorOr<void> 2021-11-17 00:21:13 +01:00
Kernel Tests: Add a test to ensure sigaltstack() is working correctly 2021-12-01 21:44:11 +02:00
LibC LibC: Fix %n conversion specifier in scanf() format 2021-10-24 22:43:27 -07:00
LibCompress Everywhere: Make ByteBuffer::{create_*,copy}() OOM-safe 2021-09-06 01:53:26 +02:00
LibCore LibCore: Fix relative seeking in IODevice 2021-11-30 10:51:10 +01:00
LibCpp Tests: Remove all file(GLOB) from CMakeLists in Tests 2021-09-02 09:08:23 +02:00
LibCrypto LibCrypto: Fix subtracting two negative SignedBigIntegers 2021-11-16 10:06:53 +00:00
LibELF LibELF: Fix dynamic linking of dlopen()-ed libs 2021-10-06 12:33:21 +02:00
LibGfx LibCore+AK: Move MappedFile from AK to LibCore 2021-11-23 11:33:36 +01:00
LibGL Tests: Add a simple LibGL render-test 2021-11-29 23:17:05 +03:30
LibIMAP Everywhere: Make ByteBuffer::{create_*,copy}() OOM-safe 2021-09-06 01:53:26 +02:00
LibJS Everywhere: Pass AK::StringView by value 2021-11-11 01:27:46 +01:00
LibM AK: Implement acos<T> correctly 2021-11-18 21:10:30 +01:00
LibMarkdown Meta: Add Meta/CMake to the CMAKE_MODULE_PATH for Serenity and Lagom 2021-09-15 19:04:52 +04:30
LibPthread LibPthread: Add first test cases for RWlock 2021-09-28 18:36:20 +03:30
LibRegex LibRegex: Avoid rewriting a+ as a* as part of atomic rewriting 2021-11-18 09:09:22 +01:00
LibSQL LibSQL: Improve error handling 2021-12-04 20:49:22 +03:30
LibThreading Tests: Disable LibThreading detach tests for now 2021-10-06 19:21:35 +02:00
LibTLS AK: Make ByteBuffer::try_* functions return ErrorOr<void> 2021-11-10 21:58:58 +01:00
LibUnicode LibUnicode: Support code point names that apply to ranges of code points 2021-11-30 11:24:02 +01:00
LibWasm LibCore: Use ErrorOr<T> for Core::File::open() 2021-11-08 00:35:27 +01:00
LibWeb Everywhere: Pass AK::StringView by value 2021-11-11 01:27:46 +01:00
UserspaceEmulator Tests: Remove all file(GLOB) from CMakeLists in Tests 2021-09-02 09:08:23 +02:00
CMakeLists.txt Tests: Add a simple LibGL render-test 2021-11-29 23:17:05 +03:30