test(libSceAudioOut): cover sceAudioOut2ContextSetAttributes argument checks #12906
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/12906"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by legendary-cookie on 2026-10-29T13:57:36Z.
What
Adds
ContextSetAttributesChecksArgumentstoAudioOut2DeviceState.cpp, on the context that test already creates:sceAudioOut2ContextSetAttributesreturnsSCE_AUDIO_OUT2_ERROR_INVALID_HANDLEfor handle 0,SCE_AUDIO_OUT2_ERROR_INVALID_ARGUMENTfor a null list with a count of 1, and 0 for a null list with a count of 0 and for a one-element list.Source:
docs/dev/debt/libSceAudioOut.mdalready records these results and that the attributes themselves are ignored; the test asserts only the return values.Tested
Windows 11, WinLibs GCC 15.2.0 UCRT r7 (the CI toolchain), Release,
BUILD_TESTING=ON, onmain95137178d0:ctest -R ^audio_out2_device_state$passes, and the 12 filesystem, Hmd2 and AudioOut2 tests pass with this branch applied together with the other two opened alongside it. Mutation-checked: returning 0 for an invalid handle or for a null list with a count, or rejecting a null list with a count of 0, each makes the test fail.tools/check_conventions.py --base origin/mainpasses;tools/pr_overlap.pyreports no overlap. Not run on Linux or macOS.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)🤖 Generated with Claude Code
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-29T14:05:31Z.
Review: APPROVED
Reviewed — looks good
On head
fd89a651a53bf5fe8c676f2b7674ff246b130459, the added argument checks match the existing implementation and debt record; the current-main merge preview is clean and conventions pass. The author reports the focused Windows test passed; I did not run the C++ test locally, and hosted policy checks were still pending.