github.com/go/docker@v1.12.0-rc2/cmd/docker/usage_test.go (about)

     1  package main
     2  
     3  import (
     4  	"sort"
     5  	"testing"
     6  
     7  	"github.com/docker/docker/cli"
     8  )
     9  
    10  // Tests if the subcommands of docker are sorted
    11  func TestDockerSubcommandsAreSorted(t *testing.T) {
    12  	if !sort.IsSorted(byName(cli.DockerCommandUsage)) {
    13  		t.Fatal("Docker subcommands are not in sorted order")
    14  	}
    15  }