Commit Graph

7 Commits (852f4552175e84b27653d33a5b23e1b6c923330a)

Author SHA1 Message Date
Eng Zer Jun 37894e9b28
test: use `T.Setenv` to set env vars in tests
This commit replaces `os.Setenv` with `t.Setenv` in tests. The
environment variable is automatically restored to its original value
when the test and all its subtests complete.

Reference: https://pkg.go.dev/testing#T.Setenv
Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2 years ago
quanweiZhou ddaf2d7623 [mem][linux] added additional meminfo fields
support HugePages_Rsvd, HugePages_Surp

Signed-off-by: quanweiZhou <quanweiZhou@linux.alibaba.com>
3 years ago
mmorel-35 1e6b445a8a gofumpt 3 years ago
shirou 0969c9436b delete v2 directory, move v3 to top #1078 3 years ago
Tom Barker 84a665b712 Add mem.SwapDevices() method. 4 years ago
Lomanic cd25417bd7 [mem][linux] Fix #1002 only try to parse /proc/meminfo numeric values on fields we're interested in 4 years ago
Lomanic 07887a9e9f [mem][linux] Add mocked test for VirtualMemory() and fix SReclaimable SUnreclaim retrieval 4 years ago