...

Source file src/edge-infra.dev/pkg/f8n/warehouse/lift/cmd/inspect/insepct_test.go

Documentation: edge-infra.dev/pkg/f8n/warehouse/lift/cmd/inspect

     1  package inspect
     2  
     3  import (
     4  	"fmt"
     5  	"os"
     6  	"testing"
     7  
     8  	"gotest.tools/v3/icmd"
     9  
    10  	"edge-infra.dev/pkg/f8n/warehouse/lift/cmd/internal/lifttest"
    11  	"edge-infra.dev/pkg/lib/build/bazel"
    12  )
    13  
    14  func TestInspectCmd(t *testing.T) {
    15  	dir, err := bazel.NewTestTmpDir("inspect-test")
    16  	if err != nil {
    17  		t.Fatal(err)
    18  	}
    19  	defer os.RemoveAll(dir)
    20  	lifttest.Setup(t, dir)
    21  	path, err := lifttest.CreateLiftBinary()
    22  	if err != nil {
    23  		t.Fatal(err)
    24  	}
    25  	result := icmd.RunCommand(path, "inspect", "-h")
    26  
    27  	fmt.Println(result.String())
    28  	icmd.RunCommand(path).Assert(t, icmd.Success)
    29  }
    30  

View as plain text