[pr-tests][linux-proton] Tests pass under Wine without changing what they check on Windows #349

Open
ntsthay wants to merge 1 commit from ntsthay/wine-tests into main AGit
First-time contributor

Tests only. Nothing here runs in the game.

Contributor role (optional)

  • Fluxer ID:

What it changes

Under Wine (Proton on Linux), some tests fail because the platform under them differs from Windows, not because Darner is wrong. Each one now checks only what that platform can show, and only under Wine. Wine is detected by the wine_get_version export of ntdll, as on_wine() already does in darner-hle and darner-gpu. On Windows every test checks what it checked before.

  • files::crash_report_files_are_registered_by_their_host_path: Wine's WerRegisterFile and WerUnregisterFile are stubs that answer E_NOTIMPL.
  • media::readers_open_files_on_virtual_drives: Wine's Media Foundation has no source for the WAV clip (0xc00d36bb). The byte stream part still runs.
  • xaudio2::xma2_voices_play_through_the_host: FAudio accepts XMA2 and does not report the queued buffer's context.
  • xgamesave::a_kept_blob_past_the_link_limit_is_copied: the temp folder is on a Linux file system, without NTFS's limit of 1024 links.
  • ramtrim::taking_pages_out_keeps_contents_write_watch_and_locks: Wine's VirtualLock keeps no lock the working set reports, so the locked page may be taken too.
  • pipeline::make::a_dispatch_waiting_on_a_worker_raises_it: the raised priority cannot be seen there.
  • pipeline::host::out_of_range_static_sampler_mip_lod_bias_serializes_for_host: vkd3d-proton does not reject the unclamped bias.
  • emit::tests::stub_pipeline_is_created: vkd3d-proton does not check the DXIL container hash.
  • rayquery_tests::a_ray_query_program_validates_and_makes_a_pipeline_on_warp and hw_tests::split_lds_wave32_read_after_read_barrier_coalescing_and_parity: Wine has no WARP adapter. The second still runs on the card and skips only its WARP part.
  • load_probe::loads_binds_and_calls_probe: the cargo it starts is the Linux one, which does not read Windows paths.
  • xtask repository_passes_policy: there is no git on the path inside Wine.

darner-shader gets its own on_wine() for tests.

How it was tested

  • Tested revision: c6d91e8, this branch on f3840d7.
  • Commands and results: each test above, with cargo nextest run under Proton (proton-cachyos, RTX 4080): all pass; on f3840d7 each fails.
  • Gates 1 and 2 are clean. Gate 3 ran under Wine, not on Windows.
  • Coverage gaps: not run on Windows. Under Wine, other tests still fail on f3840d7 and on this branch: the host font and panel tests (Wine has no Consolas, Bahnschrift or Segoe UI), the late_dll_* tests, xmem::a_title_thread_goes_on_using_the_rest_of_a_view, a BC family copy test, a buffer format test, the WARP test in ambient, and windows_is_not_wine. They are for a later PR. whole_wave_sections_keep_rounding_mode_changes passes with the shader PR.

Checklist

  • This PR contains one change based on main.
  • The diff follows docs/asset-policy.md.
  • I recorded this PR's dependencies below.
    • Depends on: none

Checked for overlap

  • I searched the open pull requests for the same issue and for the files this touches.
  • Related PRs: #150 changes write-watch tests in watch.rs, a different file.
Tests only. Nothing here runs in the game. ## Contributor role (optional) - Fluxer ID: ## What it changes Under Wine (Proton on Linux), some tests fail because the platform under them differs from Windows, not because Darner is wrong. Each one now checks only what that platform can show, and only under Wine. Wine is detected by the `wine_get_version` export of ntdll, as `on_wine()` already does in `darner-hle` and `darner-gpu`. On Windows every test checks what it checked before. - `files::crash_report_files_are_registered_by_their_host_path`: Wine's `WerRegisterFile` and `WerUnregisterFile` are stubs that answer E_NOTIMPL. - `media::readers_open_files_on_virtual_drives`: Wine's Media Foundation has no source for the WAV clip (0xc00d36bb). The byte stream part still runs. - `xaudio2::xma2_voices_play_through_the_host`: FAudio accepts XMA2 and does not report the queued buffer's context. - `xgamesave::a_kept_blob_past_the_link_limit_is_copied`: the temp folder is on a Linux file system, without NTFS's limit of 1024 links. - `ramtrim::taking_pages_out_keeps_contents_write_watch_and_locks`: Wine's `VirtualLock` keeps no lock the working set reports, so the locked page may be taken too. - `pipeline::make::a_dispatch_waiting_on_a_worker_raises_it`: the raised priority cannot be seen there. - `pipeline::host::out_of_range_static_sampler_mip_lod_bias_serializes_for_host`: vkd3d-proton does not reject the unclamped bias. - `emit::tests::stub_pipeline_is_created`: vkd3d-proton does not check the DXIL container hash. - `rayquery_tests::a_ray_query_program_validates_and_makes_a_pipeline_on_warp` and `hw_tests::split_lds_wave32_read_after_read_barrier_coalescing_and_parity`: Wine has no WARP adapter. The second still runs on the card and skips only its WARP part. - `load_probe::loads_binds_and_calls_probe`: the cargo it starts is the Linux one, which does not read Windows paths. - xtask `repository_passes_policy`: there is no `git` on the path inside Wine. `darner-shader` gets its own `on_wine()` for tests. ## How it was tested - Tested revision: `c6d91e8`, this branch on `f3840d7`. - Commands and results: each test above, with `cargo nextest run` under Proton (proton-cachyos, RTX 4080): all pass; on `f3840d7` each fails. - Gates 1 and 2 are clean. Gate 3 ran under Wine, not on Windows. - Coverage gaps: not run on Windows. Under Wine, other tests still fail on `f3840d7` and on this branch: the host font and panel tests (Wine has no Consolas, Bahnschrift or Segoe UI), the `late_dll_*` tests, `xmem::a_title_thread_goes_on_using_the_rest_of_a_view`, a BC family copy test, a buffer format test, the WARP test in `ambient`, and `windows_is_not_wine`. They are for a later PR. `whole_wave_sections_keep_rounding_mode_changes` passes with the shader PR. ## Checklist - [x] This PR contains one change based on `main`. - [x] The diff follows `docs/asset-policy.md`. - [x] I recorded this PR's dependencies below. - Depends on: none ## Checked for overlap - [x] I searched the open pull requests for the same issue and for the files this touches. - Related PRs: #150 changes write-watch tests in `watch.rs`, a different file.
ntsthay force-pushed ntsthay/wine-tests from c6d91e8281 to 33a7616529 2026-12-04 16:40:31 +00:00 Compare
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/349/head:ntsthay/wine-tests'
git switch 'ntsthay/wine-tests'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'ntsthay/wine-tests'
git switch 'ntsthay/wine-tests'
git rebase 'main'
git switch 'main'
git merge --ff-only 'ntsthay/wine-tests'
git switch 'ntsthay/wine-tests'
git rebase 'main'
git switch 'main'
git merge --no-ff 'ntsthay/wine-tests'
git switch 'main'
git merge --squash 'ntsthay/wine-tests'
git switch 'main'
git merge --ff-only 'ntsthay/wine-tests'
git switch 'main'
git merge 'ntsthay/wine-tests'
git push origin 'main'
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
TrustNo1/Darner!349
No description provided.