Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 12 additions & 2 deletions go/core.rst
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
Core go rules
=============

.. _test_filter: https://bazel.build/versions/master/docs/bazel-user-manual.html#flag--test_filter
.. _test_arg: https://bazel.build/versions/master/docs/bazel-user-manual.html#flag--test_arg
.. _test_filter: https://docs.bazel.build/versions/master/user-manual.html#flag--test_filter
.. _test_arg: https://docs.bazel.build/versions/master/user-manual.html#flag--test_arg
.. _gazelle: tools/gazelle/README.rst
.. _build constraints: http://golang.org/pkg/go/build/
.. _GoLibrary: providers.rst#GoLibrary
Expand All @@ -13,6 +13,7 @@ Core go rules
.. _Bourne shell tokenization: https://docs.bazel.build/versions/master/be/common-definitions.html#sh-tokenization
.. _data dependencies: https://docs.bazel.build/versions/master/build-ref.html#data
.. _cc library deps: https://docs.bazel.build/versions/master/be/c-cpp.html#cc_library.deps
.. _shard_count: https://docs.bazel.build/versions/master/be/common-definitions.html#test.shard_count
.. _pure: modes.rst#pure
.. _static: modes.rst#static
.. _goos: modes.rst#goos
Expand Down Expand Up @@ -497,6 +498,15 @@ Attributes
| |
| Setting it to :value:`.` makes the test behave the normal way for a bazel test. |
+----------------------------+-----------------------------+---------------------------------------+
| :param:`shard_count` | :type:`integer` | :value:`None` |
+----------------------------+-----------------------------+---------------------------------------+
| Non-negative integer less than or equal to 50, optional. |
| |
| Specifies the number of parallel shards to run the test. Test methods will be split across the |
| shards in a round-robin fashion. |
| |
| For more details on this attribute, consult the official Bazel documentation for shard_count_. |
+----------------------------+-----------------------------+---------------------------------------+

To write an internal test, reference the library being tested with the :param:`embed`
instead of :param:`deps`. This will compile the test sources into the same package as the library
Expand Down