Boot Time In Seconds From Epoch

Arguments

Get machine boot time

return:boot time in seconds from Epoch

Example:


${epoch}  Boot Time In Seconds From Epoch

Get Boot Time

Arguments

  • as_datetime: bool = False
  • datetime_format: str = %Y-%m-%d %H:%M:%S

Get computer boot time in seconds from Epoch or in datetime string.

param as_datetime:
 if True returns datetime string, otherwise seconds, defaults to False
param datetime_format:
 datetime string format, defaults to "%Y-%m-%d %H:%M:%S"
return:seconds from Epoch or datetime string

Example:


${boottime}  Get Boot Time
${boottime}  Get Boot Time   as_datetime=True
${boottime}  Get Boot Time   as_datetime=True  datetime_format=%d.%m.%Y

Get Machine Name

Arguments

Get machine name

return:machine name as string

Example:


${machine}  Get Machine Name

Get Memory Stats

Arguments

  • humanized: bool = True

Get computer memory stats and return those in bytes or in humanized memory format.

param humanized:
 if False returns memory information in bytes, defaults to True
return:memory information in dictionary format

Example:


&{mem}     Get Memory Stats
&{mem}     Get Memory Stats   humanized=False

Get Username

Arguments

Get username of logged in user

return:username as string

Example:


${user}  Get Username

Kill Process

Arguments

  • process_name: str

Kill process by name

param process_name:
 name of the process
return:True if succeeds False if not

Example:


${process}  Process Exists  calc  strict=False
${status}   Kill Process    ${process.name()}

Kill Process By Pid

Arguments

  • pid: int

Kill process by pid

param pid:process identifier

Example:


${process}  Process Exists  calc  strict=False
${status}   Kill Process    ${process.pid}

Process Exists

Arguments

  • process_name: str
  • strict: bool = True

Check if process exists by its name

param process_name:
 search for this process
param strict:defines how match is made, default True which means that process name needs to be exact match and False does inclusive matching
return:process instance or False

Example:


${process}  Process Exists  calc
${process}  Process Exists  calc  strict=False

Put System To Sleep

Arguments

Puts system to sleep mode

Example:


Put System To Sleep