@@ -703,26 +703,35 @@ via [toolchain resolution](/extending/toolchains#toolchain-resolution), just
703703like for any other action. Each test rule has an implicitly defined [
704704` test ` exec group] ( /extending/exec-groups#exec-groups-for-native-rules ) that,
705705unless overridden, has a mandatory toolchain requirement on
706- ` @bazel_tools//tools/test:default_test_toolchain_type ` . Toolchains of this type
707- do not carry any data in the form of providers, but can be used to influence the
708- execution platform of the test action. By default, Bazel registers two such
709- toolchains:
706+ ` @bazel_tools//tools/test:default_test_toolchain_type ` .
707+
708+ Toolchains of this type do not carry any data in the form of providers, but can
709+ be used to influence the execution platform of the test action.
710+
711+ Bazel registers two such toolchains, which take effect if users don't explicitly
712+ define their own::
710713
711714* If ` --@bazel_tools//tools/test:incompatible_use_default_test_toolchain ` is
712- disabled (the current default), the active test toolchain is
713- ` @bazel_tools//tools/test:legacy_test_toolchain ` . This toolchain does not
714- impose any constraints and thus test actions without manually specified exec
715- constraints are configured for the first registered execution platform. This
716- is often not the intended behavior in multi-platform builds as it can result
717- in e.g. a test binary built for Linux on a Windows machine to be executed on
718- Windows.
719- * If ` --@bazel_tools//tools/test:incompatible_use_default_test_toolchain ` is
720- enabled, the active test toolchain is
715+ enabled (** default** ), the active test toolchain is
721716 ` @bazel_tools//tools/test:default_test_toolchain ` . This toolchain requires an
722- execution platform to match all the constraints of the test rule's target
723- platform. In particular, the target platform is compatible with this toolchain
717+ execution platform to match all of the test rule's target platform
718+ constraints.
719+
720+ In particular, the target platform is compatible with this toolchain
724721 if it is also registered as an execution platform. If no such platform is
725- found, the test rule fails with a toolchain resolution error.
722+ found, the test rule fails with a toolchain resolution error
723+ * If ` --@bazel_tools//tools/test:incompatible_use_default_test_toolchain ` is
724+ disabled, the active test toolchain is
725+ ` @bazel_tools//tools/test:legacy_test_toolchain ` . This toolchain does not
726+ impose any constraints and thus test actions without manually specified exec
727+ constraints are configured for the first registered execution platform.
728+
729+ This is often not the intended behavior in multi-platform builds as it can
730+ result in, for example, a test binary built for Linux on a Windows machine to
731+ be executed on Windows.
732+
733+ As a legacy setting, expect this option to be unavailable in a future Bazel
734+ release.
726735
727736Users can register additional toolchains for this type to influence this
728737behavior and their toolchains will take precedence over the default ones.
@@ -731,8 +740,10 @@ a default toolchain for it.
731740
732741## Tag conventions { :#tag - conventions }
733742
734- Some tags in the test rules have a special meaning. See also the
735- [ Bazel Build Encyclopedia on the ` tags ` attribute] ( /reference/be/common-definitions#common.tags ) .
743+ Some tags in the test rules have a special meaning.
744+ See also the
745+ [ Bazel Build Encyclopedia on the ` tags ` attribute]
746+ (/reference/be/common-definitions#common.tags).
736747
737748<table >
738749 <tr >
0 commit comments