File: example_test.go

package info (click to toggle)
golang-github-pbnjay-memory 0.0~git20210728.7b4eea6-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 104 kB
  • sloc: makefile: 2
file content (14 lines) | stat: -rw-r--r-- 252 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
package memory_test

import (
	"fmt"

	"github.com/pbnjay/memory"
)

func ExampleTotalMemory() {
	fmt.Printf("Total system memory: %d\n", memory.TotalMemory())
}
func ExampleFreeMemory() {
	fmt.Printf("Free system memory: %d\n", memory.FreeMemory())
}