Commit Graph

8 Commits (1754b8155dfc6a43bd75cfb116cba6e47a7c3a37)

Author SHA1 Message Date
Antoine Toulme 38b94668ea allow to pass context values to override environment variables
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>
quanweiZhou ddaf2d7623 [mem][linux] added additional meminfo fields
support HugePages_Rsvd, HugePages_Surp

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