Skip to content

Unify suspend tests with and without selectable suspend mode #1020

@philipanda

Description

@philipanda

The problem you're addressing (if any)

Now we have test cases like

SUD004.202	USB devices detection after suspension (Fedora)
SUD005.202	USB devices detection after suspension (Fedora) (S0ix)
SUD006.202	USB devices detection after suspension (Fedora) (S3)

SUD004 is mutually exclusive from SUD005 and SUD006. Depending on whether the suspend mode can be changed in the setup menu, only (004), or both (005 and 006) should be performed.

Tests like SUD004 can be dropped, because it is possible to check what sleep mode is used, and the mode can even be changed from the OS

Describe the solution you'd like

On every linux and on windows too it is possible to check which supend mode is currently active, and even change it
Linux:

  • Check:
    cat /sys/power/mem_sleep
    
  • Change to S3:
    echo deep | sudo tee /sys/power/mem_sleep
    
  • Change to S0:
    echo s2idle | sudo tee /sys/power/mem_sleep
    

Windows:

  • Check:
    powercfg /a
    
  • Change to S3:
    reg add HKLM\System\CurrentControlSet\Control\Power /v PlatformAoAcOverride /t REG_DWORD /d 0
    reboot shutdown /r /t 0 /f
    
  • Change back to S0:
    reg delete "HKLM\System\CurrentControlSet\Control\Power" /v PlatformAoAcOverride /f
    reboot shutdown /r /t 0 /f
    

OSFV should check which mode is currently on and whether it can be changed to run or skip the tests for S0iX or S3. Tests for unknown sleep mode should be deprecated

Where is the value to a user, and who might that user be?

Less confusing test matrix for users and for people planning the elease scope

Describe alternatives you've considered

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions