fix(e2e): robust toggle-updates probe, storage service lifecycle, and Firefox window lookup - #792
Open
castrojo wants to merge 11 commits into
Open
fix(e2e): robust toggle-updates probe, storage service lifecycle, and Firefox window lookup#792castrojo wants to merge 11 commits into
castrojo wants to merge 11 commits into
Conversation
… Firefox window lookup 1. Probe ujust toggle-updates by checking recipe body for ACTION_VALUE rather than invoking 'ujust toggle-updates cancel' (which exited 0 without TTY even on unpatched images due to gum choose failure fallback). 2. Ensure bootc-unified-storage.service completes with Result=success before the common services scenario asserts its state. 3. In smoke suite, prioritize browser windows with address bar/tab chrome and query top-level application children in AT-SPI to prevent picking webview sub-frames. Signed-off-by: Jorge O. Castro <jorge@jorge.fyi> Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
castrojo
added a commit
to projectbluefin/bluefin
that referenced
this pull request
Sep 8, 2026
* docs: document testsuite#792 dependency for issue #989 Issue #989 blocks the :testing→main promotion. The root cause is Firefox AT-SPI test failures in run-e2e / GNOME 50 — smoke-a, which fails because Firefox window resolution incorrectly selects webview sub-frames instead of the main window with browser chrome. This is a consumer validation PR waiting for projectbluefin/testsuite#792, which adds robust window resolution logic that prioritizes top-level windows and validates presence of browser chrome (entry, autocomplete, tab list). Once testsuite#792 is merged: - The v1 tag auto-updates (via testsuite's update-v1-tag.yml) - Bluefin automatically picks up the fix (run-testsuite.yml uses @v1) - Firefox tests pass and promote-to-testing gate unblocks Refs: #989, #400 (related GNOME 50 AT-SPI issues) Signed-off-by: mrbobbytables <mrbobbytables@users.noreply.github.com> * fix(ci): remove non-workflow note file from .github/workflows --------- Signed-off-by: mrbobbytables <mrbobbytables@users.noreply.github.com> Co-authored-by: mrbobbytables <mrbobbytables@users.noreply.github.com> Co-authored-by: Jorge O. Castro <jorge.castro@gmail.com>
- Include autocomplete role in FIREFOX_CHROME_ROLES for GNOME 50 compatibility. - Add focused unit tests for address bar autocomplete role, window candidates, tab count, and fallback handling. - Document GNOME 50 Firefox AT-SPI window resolution in gnome/SKILL.md. - Update ujust-noninteractive documentation for toggle-updates probe. Assisted-by: Claude Sonnet via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- In _patch_probe, allow setting run_ssh on stubbed ssh_steps modules using raising=False so workers running after tests that injected partial ssh_steps stubs do not raise AttributeError. - In env_module fixture, evict any bare non-package tests.shared stubs left by prior tests to ensure submodule imports resolve cleanly. - Add focused regression test covering probe execution when ssh_steps stub lacks the run_ssh attribute. - Document parallel xdist helper monkeypatching in unit-test-module-stubs.md. Assisted-by: Claude Sonnet via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…d tab management fallback - Filter out Mozilla crash reporter windows in _firefox_window to avoid selecting stale crash dialogs over genuine browser windows. - Support GNOME 50 address bar combo box role and button roles in FIREFOX_CHROME_ROLES and _address_bar. - Prioritize capitalized "Firefox" in FIREFOX_APP_NAMES to eliminate 10s lookup timeout. - Provide resilient AT-SPI button fallback for tab open/close in headless Wayland container environments where uinput events are not routed to windows. - Add unit tests for crash reporter filtering, combo box recognition, and tab open/close fallbacks. - Update GNOME testing skill documentation. Assisted-by: Claude Sonnet via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…ion fallback - Cache context.firefox_app with a bounded retry loop to guard against transient AT-SPI bus lookup drops. - Fallback to set_text_contents on address bar when uinput cannot type URL characters. - Add unit tests for app handle caching, transient retry, and URL navigation fallback. Assisted-by: Claude Sonnet via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…d clean close - Patch keyboard_character_input in smoke environment to map punctuation, shifted keys, and uppercase to evdev events, avoiding NoneType unpack crashes. - Add remote IPC navigation fallback and multi-target assertion in navigate_firefox_to for headless Wayland. - Add fallback termination in firefox_is_no_longer_running when uinput Ctrl+Q is not delivered by compositor. - Add unit tests for character mapping, URL navigation variants, and shutdown fallback. - Update GNOME testing skill documentation. Assisted-by: Claude Sonnet via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Invoke firefox CLI directly via Popen/ssh_launch with arguments rather than passing command string into launch_background. - Poll for loaded page URL across address bar, document web, and tab titles for up to 7.5s. - Update unit tests with subprocess.Popen mock. Assisted-by: Claude Sonnet via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…RL navigation - Search window candidates in reverse (newest first) in _firefox_window to match newly spawned browser windows. - Check all non-crash window candidates across address bar text, document web, and tab titles in navigate_firefox_to. Assisted-by: Claude Sonnet via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…s navigation - Reuse context.firefox_window within scenario to maintain window consistency across steps. - Add bounded polling loop in _address_bar to eliminate navigation transition timing races. Assisted-by: Claude Sonnet via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Patch keyboard_key_input in smoke environment to map 'Return' to 'ENTER' in uinput evdev codes. - Use evdev native 'Enter' key name in navigate_firefox_to step. - Add unit test for key name alias mapping. Assisted-by: Claude Sonnet via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…back, and core app discovery - Automatically provision /tmp/session.env with active session variables in smoke environment to prevent POSIX /bin/sh source aborts in container mode. - Execute _run_host commands under bash with session environment preservation across steps, extensions, and system health. - Fall back to org.gnome.Shell.Extensions.ListExtensions via D-Bus when gnome-extensions CLI hangs on portal activation. - Use tree.root.applications() in _settings_app and _nautilus_app to prevent dogtail 10s blocking search freezes. - Allow Ptyxis terminal assertion to accept shell prompt window titles (user@host:~). - Add unit tests for session env execution, app list resolution, Ptyxis window title, and extension D-Bus fallbacks. - Update GNOME testing skill documentation. Assisted-by: Claude Sonnet via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This fixes multiple root causes that resulted in red E2E gates across downstream and upstream test runs:
_has_toggle_actionprobe intests/common/features/environment.py:Previously,
_has_toggle_actionprobed withtimeout 15 ujust toggle-updates cancel. In the older unpatchedupdate.justrecipe, running without a TTY causedgum chooseto fail and setSELECTED_OPTION="", which hit[[ "${SELECTED_OPTION}" == "Cancel" || "${SELECTED_OPTION}" == "" ]] && exit 0. Thus the probe exited 0 even on unpatched images (such asbluefin:testing), falsely activating the non-interactive toggle scenario that subsequently failed.The probe now inspects the recipe body via
ujust --show toggle-updates 2>/dev/null | grep -q 'ACTION_VALUE'.bootc-unified-storage.servicelifecycle:In
tests/common/features/common_services.feature,bootc unified storage service completed successfullyassertssystemctl show bootc-unified-storage.service --property=Result --valueissuccess. If the service was interrupted or stopped with a signal during earlier runner setup or boot,before_scenariorestarts it so it runs to completion before the check runs.Firefox window resolution in
tests/smoke/features/steps/firefox_steps.py:In GNOME 50,
_window_candidatesused recursivefindChildrenover the entire AT-SPI tree of Firefox, which discovered iframe/webview sub-frames. When an iframe withpush buttonwas found,_firefox_windowpreferred it as aframeover the top-levelfillerwindow that contained the actual browser chrome (address bar and tabs), causingAddress bar is present in Firefoxto fail._window_candidatesnow checks immediate application children first and prioritizes windows exposing browser chrome (entry,autocomplete,page tab list).Validation
pytest tests/unit/test_common_steps.py tests/unit/test_firefox_steps.pypasses with all 74 unit tests green.python3 -m py_compileclean across all touched files.Signed-off-by: Jorge O. Castro jorge@jorge.fyi
Co-authored-by: Copilot 223556219+Copilot@users.noreply.github.com