官术网_书友最值得收藏!

Running tests in nil_test.go

We run three tests, where two test cases will pass and one will fail. This way we can see the tick mark and cross mark in action:

$ go test -v ./nil_test.go                                          
=== RUN   TestServer                       
=== RUN   TestServer/Request_correct_URL   
=== RUN   TestServer/Request_incorrect_URL 
=== RUN   TestServer/Fail_for_no_reason    
--- FAIL: TestServer (0.00s)               
  --- PASS: TestServer/Request_correct_URL (0.00s)                                  
        nil_test.go:55: Got 1. == Got 1.  
  --- PASS: TestServer/Request_incorrect_URL (0.00s)                                
        nil_test.go:55: Got None. == Got None. 
--- FAIL: TestServer/Fail_for_no_reason (0.00s)
nil_test.go:59: + != -
FAIL
exit status 1
FAIL command-line-arguments 0.003s
主站蜘蛛池模板: 托克逊县| 隆昌县| 宁河县| 拜城县| 中西区| 晋州市| 大埔区| 烟台市| 南木林县| 岑溪市| 博白县| 潞西市| 黄大仙区| 新干县| 鄄城县| 平武县| 无为县| 东港市| 芒康县| 务川| 芮城县| 比如县| 双柏县| 会昌县| 金坛市| 青河县| 佛学| 昌吉市| 建始县| 新兴县| 武定县| 敦煌市| 庆元县| 芦溪县| 昌邑市| 增城市| 双江| 文山县| 台中县| 莫力| 张家口市|