mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2024-11-25 09:39:25 +01:00
auto-t: fix testEncryptedProfiles mtime check
Yet another weird UML quirk. The intent of this tests was to ensure the profile gets encrypted, and to check this both the mtime and contents of the profile were checked. But under UML the profile is copied, IWD started, and the profile is encrypted all without any time passing. The (same) mtime was then updated without any changes which fails the mtime check. This puts a sleep after copying the profile to ensure the system time differs once IWD encrypts the profile.
This commit is contained in:
parent
1ecadc3952
commit
53e8bf4cb0
@ -6,6 +6,7 @@ import sys
|
||||
sys.path.append('../util')
|
||||
import iwd
|
||||
import os
|
||||
from time import sleep
|
||||
from iwd import IWD
|
||||
from iwd import NetworkType
|
||||
from iwd import PSKAgent
|
||||
@ -48,6 +49,8 @@ class Test(unittest.TestCase):
|
||||
mtime = os.path.getmtime('/tmp/iwd/' + 'ssidCCMP.psk')
|
||||
self.assertFalse(self.profile_is_encrypted('ssidCCMP.psk'))
|
||||
|
||||
sleep(1)
|
||||
|
||||
wd = IWD(True)
|
||||
|
||||
# Make sure profile was accepted
|
||||
|
Loading…
Reference in New Issue
Block a user