← Back to issue list

tests: fix electron spread test

View original Github issue

Metadata

Project
snapcraft
Number
#3944
Type
pull request
State
merged
Author
mr-cal
Labels
Created
Updated
Closed

Current evaluation

Merged a fix for a failing electron spread test. Updated the expected snap.yaml to include the TMPDIR environment variable, resolving a diff mismatch.

Suggested action:

No scores available.

Issue body

Signed-off-by: Callahan Kovacs <callahan.kovacs@canonical.com> - [X] Have you followed the [guidelines for contributing](https://github.com/snapcore/snapcraft/blob/master/CONTRIBUTING.md)? - [X] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)? - [X] Have you successfully run `make lint`? - [X] Have you successfully run `pytest tests/unit`? ----- I'm not sure if this is a "fix" or a "hack", nor why it started failing, but [this spread test](https://github.com/snapcore/snapcraft/tree/main/tests/spread/electron-builder/no-template) is failing with the error: ``` + diff -U10 /snap/electron-builder-hello-world/x1/meta/snap.yaml /snapcraft/tests/spread/electron-builder/no-template/expected_snap.yaml --- /snap/electron-builder-hello-world/x1/meta/snap.yaml 2022-10-07 18:27:23.000000000 +0000 +++ /snapcraft/tests/spread/electron-builder/no-template/expected_snap.yaml 2021-04-29 15:11:51.000000000 +0000 @@ -14,20 +14,21 @@ - unity7 - browser-support - network - gsettings - audio-playback - pulseaudio - opengl - raw-usb environment: DISABLE_WAYLAND: '1' + TMPDIR: $XDG_RUNTIME_DIR PATH: $SNAP/usr/sbin:$SNAP/usr/bin:$SNAP/sbin:$SNAP/bin:$PATH SNAP_DESKTOP_RUNTIME: $SNAP/gnome-platform LD_LIBRARY_PATH: $SNAP_LIBRARY_PATH:$SNAP/lib:$SNAP/usr/lib:$SNAP/lib/x86_64-linux-gnu:$SNAP/usr/lib/x86_64-linux-gnu:$LD_LIBRARY_PATH:$SNAP/lib:$SNAP/usr/lib:$SNAP/lib/x86_64-linux-gnu:$SNAP/usr/lib/x86_64-linux-gnu architectures: - amd64 base: core18 confinement: strict grade: stable plugs: gnome-3-28-1804: + echo 'snap.yaml does not match expected:' snap.yaml does not match expected: ```

Evaluation history

Date Model Scores Action Summary
qwen/qwen3.6-35b-a3b Merged a fix for a failing electron spread test. Updated the expected snap.yaml to include the TMPDIR environment variable, resolving a diff mismatch.
qwen3.6-35b-a3b-mtp-q6 Merged a fix for a failing electron spread test by adding the missing TMPDIR environment variable to the expected snap.yaml, aligning it with generated output and resolving the test failure.
qwen3.6-35b-a3b-mtp-q6 Merged a fix for a failing electron spread test by adding the missing TMPDIR environment variable to the expected snap.yaml, resolving the diff mismatch.

Update history

No update history recorded yet.

Related issues

Issue Project State Summary Similarity
#3323 electron-builder spread test: sync expected snapcraft.yaml snapcraft merged Merged to sync the expected snapcraft.yaml in the electron-builder spread test with upstream updates. Approved by one reviewer, updating one file with nine additions and one deletion.
76%
#3312 spread tests: introduce electron-builder test snapcraft merged Merged test case for electron-builder with useTemplate false. Compares generated snapcraft and meta YAML files to track upstream updates. Approved, passed CI, and added 385 lines across 11 files.
75%
#3454 spread: update electron-builder test snapcraft merged Merged after approval by two reviewers and passing CI checks. Updates the electron-builder test in the spread testing framework, modifying two files to align test expectations.
72%
#2745 tests: update spread tests to account for content snaps snapcraft merged Merged updates to spread tests for gnome and kde extensions to handle content snaps and use gtk. Removed unnecessary snap cleanup logic per reviewer feedback, relying on restore-each for environment purging. Added a NOMATCH helper. Approved and merged.
71%
#1068 tests: use a temporary directory for snaps tests snapcraft merged Merged into master. Updated snap tests to use a temporary directory, resolving Launchpad bug #1643658. Approved by reviewer, passed CI, and maintained full test coverage.
70%