|
You are here |
me.micahrl.com | ||
| | | | |
blog.djy.io
|
|
| | | | | ||
| | | | |
jmmv.dev
|
|
| | | | | About two weeks ago, I found a very interesting bug in Bazel's test output streaming functionality while writing tests for a new feature related to Ctrl+C interrupts. I fixed the bug, wrote a test for it, and... the test itself came back as flaky, which made me find another very subtle bug in the test that needed a one-line fix. This is the story of both. Bazel has a feature known as test output streaming: by default, Bazel captures the outputs (stdout and stderr) of the tests it runs, saves those in local log files, and tells the user where they are when a test fails. This is not very ergonomic when you are iterating on a test, so you can make Bazel print the output of the test as it runs by passing --test_output=streamed to the invocation. | |
| | | | |
rickardlindberg.me
|
|
| | | | | I thought I knew how Bash redirects worked. If I wanted to redirect the output of a command to a file, I'd type this: program > /tmp/log.txt If I wanted to pipe both stdout and stderr to a text editor for further processing, I'd type this: program 2>&1 | vim - I knew that 2>&1 meant redirect stderr to stdout making it appear on stdout as well. I knew certain patterns for certain situations. | |
| | | | |
taingram.org
|
|
| | | |||