public static Status assertStatus(final Status.Code expectedCode, final StatusRuntimeException exception) {
        final Status status = exception.getStatus();
        assertEquals(expectedCode, status.getCode());
        return status;
    }
Asserts that the given {@link StatusRuntimeException} uses the expected status code.

@param expectedCode The expected status code.
@param exception The exception to check for the status code.
@return The status contained in the exception.
tests/src/test/java/net/devh/boot/grpc/test/util/GrpcAssertions.java