aboutsummaryrefslogtreecommitdiffstats
path: root/components/servo/tests
Commit message (Collapse)AuthorAgeFilesLines
* script: Unconditionally send exit message during pipeline shutdown (#36808)Martin Robinson46 hours1-1/+13
| | | | | | | | | | | | If a `WebView` is dropped immediately after creating it, the exit pipeline message can arrive to the `ScriptThread` before the `Document` is created for the pipeline. If this happens, we should still send a message to the `Constellation` informing it that the pipeline is closed, otherwise it will never know that this has happened properly. Testing: This change includes a new unit test. Fixes: #36807. Signed-off-by: Martin Robinson <mrobinson@igalia.com>
* libservo: Add a basic `WebView` API test (#36791)Martin Robinson5 days3-70/+117
| | | | | | | This should allow us to start unit testing the `WebView` API. Testing: This is a test. Signed-off-by: Martin Robinson <mrobinson@igalia.com>
* libservo: Expose a `ServoBuilder` (#36549)Martin Robinson2025-04-161-17/+4
| | | | | | | | | Expose a `ServoBuilder` for easily creating Servo instances using default values. This change enables removing `EmbedderTraits`. Testing: This is covered by `Servo` unit tests. Signed-off-by: Martin Robinson <mrobinson@igalia.com> Signed-off-by: Martin Robinson <mrobinson@igalia.com>
* libservo: Allow running more than one Servo test in a run (#36532)Martin Robinson2025-04-162-12/+88
| | | | | | | | | | A `Servo` instance can only be constructed once per program execution and cannot be passed between threads. This change adds a special thread to run `Servo` unit tests. This will allow creating suites of `WebView` unit tests. Testing: This change includes a new test. Signed-off-by: Martin Robinson <mrobinson@igalia.com>
* libservo: Make zooming and HiDPI scaling work per-`WebView` (#36419)Martin Robinson2025-04-141-11/+1
| | | | | | | | | | | | | | | | | | | | | | | | libservo: Make zooming and HiDPI scaling work per-`WebView` This change moves all zooming and HiDPI scaling to work per-`WebView` in both libservo and Compositor. This means that you can pinch zoom one `WebView` and it should now work independently of other `WebView`s. This is accomplished by making each `WebView` in the WebRender scene have its own scaling reference frame. All WebViews are now expected to manage their HiDPI scaling factor and this can be set independently of other WebViews. Perhaps in the future this will become a Servo-wide setting. This allows full removal of the `WindowMethods` trait from Servo. Testing: There are not yet any tests for the WebView API, but I hope to add those soon. Co-authored-by: Shubham Gupta <shubham13297@gmail.com> Signed-off-by: Martin Robinson <mrobinson@igalia.com> Signed-off-by: Martin Robinson <mrobinson@igalia.com> Co-authored-by: Shubham Gupta <shubham13297@gmail.com>
* libservo: Add a very simple `libservo` API test (#36440)Martin Robinson2025-04-122-0/+99
libservo: Add a very simple `libservo` API test This is the first step toward adding full testing for the `WebView` API. The test added here simply starts up a Servo instance and verifies that it does not crash when shutting down. Testing: This change is a test, so there are tests for these changes. Signed-off-by: Martin Robinson <mrobinson@igalia.com> Signed-off-by: Martin Robinson <mrobinson@igalia.com>