mirror of
https://github.com/reactos/syzkaller.git
synced 2024-11-24 11:59:58 +00:00
19 lines
415 B
Go
19 lines
415 B
Go
// Copyright 2017 syzkaller project authors. All rights reserved.
|
|
// Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file.
|
|
|
|
package osutil
|
|
|
|
import (
|
|
"os"
|
|
"testing"
|
|
)
|
|
|
|
func TestIsExist(t *testing.T) {
|
|
if f := os.Args[0]; !IsExist(f) {
|
|
t.Fatalf("executable %v does not exist", f)
|
|
}
|
|
if f := os.Args[0] + "-foo-bar-buz"; IsExist(f) {
|
|
t.Fatalf("file %v exists", f)
|
|
}
|
|
}
|