Merge "Add test for tracing onFlush()" into main