github.com/ratrocket/u-root@v0.0.0-20180201221235-1cf9f48ee2cf/cmds/ps/ps_test.go (about) 1 // Copyright 2016 the u-root Authors. All rights reserved 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 // created by Manoel Vilela (manoel_vilela@engineer.com) 6 7 package main 8 9 import ( 10 "testing" 11 ) 12 13 // Simple Test trying execute the ps 14 // If no errors returns, it's okay 15 func TestPsExecution(t *testing.T) { 16 pT := ProcessTable{} 17 if err := pT.LoadTable(); err != nil { 18 t.Fatalf("Loading Table fails on some point; %v", err) 19 } 20 21 if err := ps(pT); err != nil { 22 t.Fatalf("Calling ps fails; %v", err) 23 } 24 }