getrandom is implemented as a syscall.
We don't want to test linux implementation of the syscall. We just want to verify that it reacts as expected to sensible values.
Runtime before
[ RUN ] LlvmLibcGetRandomTest.InvalidFlag [ OK ] LlvmLibcGetRandomTest.InvalidFlag (took 0 ms) [ RUN ] LlvmLibcGetRandomTest.InvalidBuffer [ OK ] LlvmLibcGetRandomTest.InvalidBuffer (took 0 ms) [ RUN ] LlvmLibcGetRandomTest.ReturnsSize [ OK ] LlvmLibcGetRandomTest.ReturnsSize (took 83 ms) [ RUN ] LlvmLibcGetRandomTest.PiEstimation [ OK ] LlvmLibcGetRandomTest.PiEstimation (took 9882 ms)
Runtime after
[ RUN ] LlvmLibcGetRandomTest.InvalidFlag [ OK ] LlvmLibcGetRandomTest.InvalidFlag (took 0 ms) [ RUN ] LlvmLibcGetRandomTest.InvalidBuffer [ OK ] LlvmLibcGetRandomTest.InvalidBuffer (took 0 ms) [ RUN ] LlvmLibcGetRandomTest.ReturnsSize [ OK ] LlvmLibcGetRandomTest.ReturnsSize (took 0 ms) [ RUN ] LlvmLibcGetRandomTest.CheckValue [ OK ] LlvmLibcGetRandomTest.CheckValue (took 0 ms)
I think these are redundant, ErrnoSetterMatcher does reset libc_errno to 0 after matching.