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