std: silence warnings when compiling test.
extra: silence warnings during testing.
auto merge of #11071 : huonw/rust/quiet-test, r=cmr