mirror of
https://github.com/genuinetools/reg.git
synced 2024-09-12 06:11:03 -04:00
19 lines
236 B
Go
19 lines
236 B
Go
![]() |
// +build linux
|
||
|
|
||
|
package cgroups
|
||
|
|
||
|
import (
|
||
|
"testing"
|
||
|
)
|
||
|
|
||
|
func TestParseCgroups(t *testing.T) {
|
||
|
cgroups, err := ParseCgroupFile("/proc/self/cgroup")
|
||
|
if err != nil {
|
||
|
t.Fatal(err)
|
||
|
}
|
||
|
|
||
|
if _, ok := cgroups["cpu"]; !ok {
|
||
|
t.Fail()
|
||
|
}
|
||
|
}
|