File tree Expand file tree Collapse file tree 2 files changed +21
-15
lines changed
documentation/src/docs/asciidoc/user-guide Expand file tree Collapse file tree 2 files changed +21
-15
lines changed Original file line number Diff line number Diff line change @@ -154,21 +154,6 @@ $ java -jar junit-platform-console-standalone-{platform-version}.jar <OPTIONS> \
154
154
--config-resource=configuration.properties
155
155
----
156
156
157
- You can redirect standard output and standard error using the `--redirect-stdout` and
158
- `--redirect-stderr` options:
159
-
160
- [source,console,subs=attributes+]
161
- ----
162
- $ java -jar junit-platform-console-standalone-{platform-version}.jar <OPTIONS> \
163
- --redirect-stdout=foo.txt \
164
- --redirect-stderr=bar.txt
165
- ----
166
-
167
- If both the `--redirect-stdout` and `--redirect-stderr` parameters point to the same
168
- file, the output will be merged into that file.
169
-
170
- The default charset is used for writing to the files.
171
-
172
157
[[junit-platform-reporting-legacy-xml]]
173
158
==== Legacy XML format
174
159
Original file line number Diff line number Diff line change @@ -812,6 +812,27 @@ You can pass a real parameter with an initial `@` character by escaping it with
812
812
additional `@` symbol. For example, `@@somearg` will become `@somearg` and will not be
813
813
subject to expansion.
814
814
815
+ [[running-tests-console-launcher-redirecting-stdout-and-stderr]]
816
+ ==== Redirecting Standard Output/Error to Files
817
+
818
+ You can redirect the `System.out` (stdout) and `System.err` (stderr) output streams to
819
+ files using the `--redirect-stdout` and `--redirect-stderr` options:
820
+
821
+ [source,console,subs=attributes+]
822
+ ----
823
+ $ java -jar junit-platform-console-standalone-{platform-version}.jar <OPTIONS> \
824
+ --redirect-stdout=stdout.txt \
825
+ --redirect-stderr=stderr.txt
826
+ ----
827
+
828
+ [NOTE]
829
+ ====
830
+ If the `--redirect-stdout` and `--redirect-stderr` arguments point to the same file, both
831
+ output streams will be redirected to that file.
832
+
833
+ The default charset is used for writing to the files.
834
+ ====
835
+
815
836
[[running-tests-console-launcher-color-customization]]
816
837
==== Color Customization
817
838
You can’t perform that action at this time.
0 commit comments