from datetime import datetime, timedelta
sh.Command('unsuspend_user')(user)
if 'autosuspend.yaml' in file:
(datetime.now() - timedelta(days=90)).strftime("%s"),
(datetime.now() - timedelta(seconds=90)).strftime("%s"),
elif 'sa_interval.yaml' in file:
"argosy6 3 0.00re 150.00cp 27499k",
"fooba 6 0.12re 9000.01cp 2799k",
"clyde 4 0.12re 9000.01cp 2799k",
"herrew5 4 0.12re 15.00cp 2799k",
"baduser 4 0.12re 9000.01cp 2799k",
def tmpdir_config(tmpdir):
conf = tmpdir.mkdir('etc').join('autosuspend.cfg')
opsdir = tmpdir.mkdir('ops')
logfile = tmpdir.mkdir('log').join('suspension.log')
fixture_config = ConfigParser.ConfigParser()
fixture_config.add_section('settings')
fixture_config.set('settings', 'opfiles', str(opsdir))
fixture_config.set('settings', 'suspension_log', str(logfile))
with open(str(conf), 'w') as fp: