tree: 8e106b4f2f7e99f8f68689b03c398c181432ebf5 [path history] [tgz]
  1. abi/
  2. alias3.dir/
  3. arenas/
  4. asmhdr.dir/
  5. chan/
  6. closure3.dir/
  7. closure5.dir/
  8. codegen/
  9. ddd2.dir/
  10. dwarf/
  11. fixedbugs/
  12. import2.dir/
  13. import4.dir/
  14. interface/
  15. intrinsic.dir/
  16. ken/
  17. linkname.dir/
  18. method4.dir/
  19. retjmp.dir/
  20. runtime/
  21. stress/
  22. syntax/
  23. typeparam/
  24. uintptrescapes.dir/
  25. 235.go
  26. 64bit.go
  27. alg.go
  28. alias.go
  29. alias1.go
  30. alias2.go
  31. alias3.go
  32. align.go
  33. append.go
  34. append1.go
  35. args.go
  36. armimm.go
  37. asmhdr.go
  38. assign.go
  39. assign1.go
  40. atomicload.go
  41. bigalg.go
  42. bigmap.go
  43. blank.go
  44. blank1.go
  45. bom.go
  46. bombad.go
  47. bounds.go
  48. cannotassign.go
  49. chancap.go
  50. chanlinear.go
  51. char_lit.go
  52. char_lit1.go
  53. checkbce.go
  54. clear.go
  55. clearfat.go
  56. closedchan.go
  57. closure.go
  58. closure1.go
  59. closure2.go
  60. closure3.go
  61. closure4.go
  62. closure5.go
  63. closure6.go
  64. closure7.go
  65. cmp.go
  66. cmp6.go
  67. cmplx.go
  68. cmplxdivide.c
  69. cmplxdivide.go
  70. cmplxdivide1.go
  71. complit.go
  72. complit1.go
  73. compos.go
  74. const.go
  75. const1.go
  76. const2.go
  77. const3.go
  78. const4.go
  79. const5.go
  80. const6.go
  81. const7.go
  82. const8.go
  83. convert.go
  84. convert1.go
  85. convert2.go
  86. convert3.go
  87. convert4.go
  88. convinline.go
  89. convlit.go
  90. convlit1.go
  91. convT2X.go
  92. copy.go
  93. copy1.go
  94. crlf.go
  95. ddd.go
  96. ddd1.go
  97. ddd2.go
  98. decl.go
  99. declbad.go
  100. defer.go
  101. defererrcheck.go
  102. deferfin.go
  103. defernil.go
  104. deferprint.go
  105. deferprint.out
  106. devirt.go
  107. directive.go
  108. directive2.go
  109. divide.go
  110. divmod.go
  111. embedfunc.go
  112. embedvers.go
  113. empty.go
  114. env.go
  115. eof.go
  116. eof1.go
  117. escape.go
  118. escape2.go
  119. escape2n.go
  120. escape3.go
  121. escape4.go
  122. escape5.go
  123. escape_array.go
  124. escape_calls.go
  125. escape_closure.go
  126. escape_field.go
  127. escape_goto.go
  128. escape_hash_maphash.go
  129. escape_iface.go
  130. escape_indir.go
  131. escape_level.go
  132. escape_map.go
  133. escape_param.go
  134. escape_reflect.go
  135. escape_runtime_atomic.go
  136. escape_selfassign.go
  137. escape_slice.go
  138. escape_struct_param1.go
  139. escape_struct_param2.go
  140. escape_struct_return.go
  141. escape_sync_atomic.go
  142. escape_unsafe.go
  143. fibo.go
  144. finprofiled.go
  145. float_lit.go
  146. float_lit2.go
  147. float_lit3.go
  148. floatcmp.go
  149. for.go
  150. func.go
  151. func1.go
  152. func2.go
  153. func3.go
  154. func4.go
  155. func5.go
  156. func6.go
  157. func7.go
  158. func8.go
  159. funcdup.go
  160. funcdup2.go
  161. fuse.go
  162. gc.go
  163. gc1.go
  164. gc2.go
  165. gcgort.go
  166. gcstring.go
  167. goprint.go
  168. goprint.out
  169. goto.go
  170. heapsampling.go
  171. helloworld.go
  172. helloworld.out
  173. if.go
  174. import.go
  175. import1.go
  176. import2.go
  177. import4.go
  178. import5.go
  179. import6.go
  180. index.go
  181. index0.go
  182. index1.go
  183. index2.go
  184. indirect.go
  185. indirect1.go
  186. init.go
  187. init1.go
  188. initcomma.go
  189. initexp.go
  190. initialize.go
  191. initializerr.go
  192. initloop.go
  193. inline.go
  194. inline_big.go
  195. inline_caller.go
  196. inline_callers.go
  197. inline_endian.go
  198. inline_literal.go
  199. inline_math_bits_rotate.go
  200. inline_sync.go
  201. inline_variadic.go
  202. int_lit.go
  203. intcvt.go
  204. intrinsic.go
  205. intrinsic_atomic.go
  206. iota.go
  207. label.go
  208. label1.go
  209. linkmain.go
  210. linkmain_run.go
  211. linkname.go
  212. linkname3.go
  213. linkobj.go
  214. linkx.go
  215. linkx_run.go
  216. literal.go
  217. literal2.go
  218. live.go
  219. live1.go
  220. live2.go
  221. live_regabi.go
  222. live_uintptrkeepalive.go
  223. loopbce.go
  224. mainsig.go
  225. makechan.go
  226. makemap.go
  227. makenew.go
  228. makeslice.go
  229. mallocfin.go
  230. map.go
  231. map1.go
  232. mapclear.go
  233. maplinear.go
  234. maymorestack.go
  235. mergemul.go
  236. method.go
  237. method1.go
  238. method2.go
  239. method3.go
  240. method4.go
  241. method5.go
  242. method6.go
  243. method7.go
  244. named.go
  245. named1.go
  246. nil.go
  247. nilcheck.go
  248. nilptr.go
  249. nilptr2.go
  250. nilptr3.go
  251. nilptr4.go
  252. nilptr5.go
  253. nilptr5_aix.go
  254. nilptr5_wasm.go
  255. nilptr_aix.go
  256. noinit.go
  257. nosplit.go
  258. nowritebarrier.go
  259. nul1.go
  260. opt_branchlikely.go
  261. parentype.go
  262. peano.go
  263. phiopt.go
  264. print.go
  265. print.out
  266. printbig.go
  267. printbig.out
  268. prove.go
  269. prove_constant_folding.go
  270. range.go
  271. README.md
  272. recover.go
  273. recover1.go
  274. recover2.go
  275. recover3.go
  276. recover4.go
  277. recover5.go
  278. reflectmethod1.go
  279. reflectmethod2.go
  280. reflectmethod3.go
  281. reflectmethod4.go
  282. reflectmethod5.go
  283. reflectmethod6.go
  284. reflectmethod7.go
  285. reflectmethod8.go
  286. rename.go
  287. rename1.go
  288. reorder.go
  289. reorder2.go
  290. retjmp.go
  291. return.go
  292. rotate.go
  293. rotate0.go
  294. rotate1.go
  295. rotate2.go
  296. rotate3.go
  297. rune.go
  298. runtime.go
  299. shift1.go
  300. shift2.go
  301. shift3.go
  302. sieve.go
  303. sigchld.go
  304. sigchld.out
  305. simassign.go
  306. sizeof.go
  307. slice3.go
  308. slice3err.go
  309. slicecap.go
  310. sliceopt.go
  311. solitaire.go
  312. stack.go
  313. stackobj.go
  314. stackobj2.go
  315. stackobj3.go
  316. strcopy.go
  317. strength.go
  318. string_lit.go
  319. stringrange.go
  320. struct0.go
  321. switch.go
  322. switch2.go
  323. switch3.go
  324. switch4.go
  325. switch5.go
  326. switch6.go
  327. switch7.go
  328. tighten.go
  329. tinyfin.go
  330. torture.go
  331. turing.go
  332. typecheck.go
  333. typecheckloop.go
  334. typeswitch.go
  335. typeswitch1.go
  336. typeswitch2.go
  337. typeswitch2b.go
  338. typeswitch3.go
  339. uintptrescapes.go
  340. uintptrescapes2.go
  341. uintptrescapes3.go
  342. uintptrkeepalive.go
  343. undef.go
  344. unsafe_slice_data.go
  345. unsafe_string.go
  346. unsafe_string_data.go
  347. unsafebuiltins.go
  348. used.go
  349. utf.go
  350. varerr.go
  351. varinit.go
  352. winbatch.go
  353. writebarrier.go
  354. zerodivide.go
  355. zerosize.go
test/README.md

The test directory contains tests of the Go tool chain and runtime. It includes black box tests, regression tests, and error output tests. They are run as part of all.bash.

To run just these tests, execute:

../bin/go test cmd/internal/testdir

To run just tests from specified files in this directory, execute:

../bin/go test cmd/internal/testdir -run='Test/(file1.go|file2.go|...)'

Standard library tests should be written as regular Go tests in the appropriate package.

The tool chain and runtime also have regular Go tests in their packages. The main reasons to add a new test to this directory are:

  • it is most naturally expressed using the test runner; or
  • it is also applicable to gccgo and other Go tool chains.