qt6-bb10/tests/auto/corelib/serialization
Axel Spoerl ccd8a496cf QXmlStreamReader::readNextStartElement() - return false on document end
The method reads the next element in a loop, as long as valid elements
exist. Within the loop, it returns
- false if the end of an element has been reached
- true if a new element has started

When the document end has been reached, the loop continues, until
readNext() returns Invalid. Then, PrematureEndOfDocumentError is launched.

This is wrong, because reading beyond the document end is caused by a
missing return condition in the loop.

=> Treat document end like element end and return false without
reading beyond it.

=> Test correct behavior in tst_QXmlStream::readNextStartElement()

Fixes: QTBUG-25944
Pick-to: 6.6 6.5 6.2
Change-Id: I0160b65880756a2be541e9f55dc79557fcb1f09f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2023-08-15 07:16:31 +02:00
..
json CMake: Make corelib tests standalone projects 2023-07-05 15:09:32 +02:00
qcborstreamreader CI: Enable tests under corelib/serialization for Wasm platform 2023-08-14 16:08:32 +02:00
qcborstreamwriter CI: Enable tests under corelib/serialization for Wasm platform 2023-08-14 16:08:32 +02:00
qcborvalue CI: Enable tests under corelib/serialization for Wasm platform 2023-08-14 16:08:32 +02:00
qcborvalue_json CMake: Make corelib tests standalone projects 2023-07-05 15:09:32 +02:00
qdatastream CI: Enable tests under corelib/serialization for Wasm platform 2023-08-14 16:08:32 +02:00
qdatastream_core_pixmap CI: Enable tests under corelib/serialization for Wasm platform 2023-08-14 16:08:32 +02:00
qtextstream CMake: Make corelib tests standalone projects 2023-07-05 15:09:32 +02:00
qxmlstream QXmlStreamReader::readNextStartElement() - return false on document end 2023-08-15 07:16:31 +02:00
CMakeLists.txt CI: Enable tests under corelib/serialization for Wasm platform 2023-08-14 16:08:32 +02:00
cborlargedatavalidation.cpp CI: Enable tests under corelib/serialization for Wasm platform 2023-08-14 16:08:32 +02:00