parent
3088a2452a
commit
6fe273cf8b
1 changed files with 8 additions and 4 deletions
|
|
@ -59,6 +59,14 @@ class CpuObj():
|
|||
report.append('{BLUE}Device{CLEAR}'.format(**COLORS))
|
||||
report.append(' {}'.format(self.name))
|
||||
|
||||
# Include RAM details
|
||||
ram_details = get_ram_details()
|
||||
ram_total = human_readable_size(ram_details.pop('Total', 0)).strip()
|
||||
ram_dimms = ['{}x {}'.format(v, k) for k, v in sorted(ram_details.items())]
|
||||
report.append(' ')
|
||||
report.append('{BLUE}RAM{CLEAR}'.format(**COLORS))
|
||||
report.append(' {} ({})'.format(ram_total, ', '.join(ram_dimms)))
|
||||
|
||||
# Tests
|
||||
for test in self.tests.values():
|
||||
report.extend(test.report)
|
||||
|
|
@ -760,10 +768,6 @@ def get_ram_details():
|
|||
result = run_program(cmd, encoding='utf-8', errors='ignore')
|
||||
dmi_data = result.stdout.splitlines()
|
||||
|
||||
# Testing
|
||||
with open('dmi_mem.log', 'r') as f:
|
||||
dmi_data = f.readlines()
|
||||
|
||||
# Parse data
|
||||
for line in dmi_data:
|
||||
line = line.strip()
|
||||
|
|
|
|||
Loading…
Reference in a new issue