File: process_openbsd_test.go

package info (click to toggle)
golang-github-keybase-go-ps 0.0~git20190827.91aafc9-1.1
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 152 kB
  • sloc: ansic: 61; makefile: 2
file content (28 lines) | stat: -rw-r--r-- 458 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// +build openbsd

package ps

import (
	"testing"

	"github.com/stretchr/testify/assert"
)

func TestFindProcessOpenBSD(t *testing.T) {
	proc := testFindProcess(t, "go-ps.test")
	assert.True(t, proc.PPid() > 0)
}

func TestProcessesOpenBSD(t *testing.T) {
	testProcesses(t, "go")
}

/*
// Currently querying for -1 will return -1 :P

func TestProcessesOpenBSDError(t *testing.T) {
	proc, err := findProcess(-1)
	assert.Nil(t, proc)
	assert.Nil(t, err)
}
*/