File: counted_test.go

package info (click to toggle)
golang-github-docopt-docopt-go 0.6.2%2Bgit20180111.ee0de3b-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, forky, sid, trixie
  • size: 284 kB
  • sloc: makefile: 10
file content (36 lines) | stat: -rw-r--r-- 702 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
29
30
31
32
33
34
35
36
package main

import (
	"github.com/docopt/docopt-go/examples"
)

func Example() {
	examples.TestUsage(usage, "counted -vvvvvvvvvv")
	examples.TestUsage(usage, "counted go go")
	examples.TestUsage(usage, "counted --path ./here --path ./there")
	examples.TestUsage(usage, "counted this.txt that.txt")
	// Output:
	//    --help false
	//    --path []
	//        -v 10
	//    <file> []
	//        go 0
	//
	//    --help false
	//    --path []
	//        -v 0
	//    <file> []
	//        go 2
	//
	//    --help false
	//    --path [./here ./there]
	//        -v 0
	//    <file> []
	//        go 0
	//
	//    --help false
	//    --path []
	//        -v 0
	//    <file> [this.txt that.txt]
	//        go 0
}