### Question:
CommonsMathWrapper { public static RealMatrix wrap(DoubleMatrix x) { ArgChecker.notNull(x, "x"); return new Array2DRowRealMatrix(x.toArrayUnsafe()); } private  CommonsMathWrapper(); static UnivariateFunction wrapUnivariate(Function<Double, Double> f); static RealMatrix wrap(DoubleMatrix x); static RealMatrix wrapAsMatrix(DoubleArray x); static DoubleMatrix unwrap(RealMatrix x); static RealVector wrap(DoubleArray x); static DoubleArray unwrap(RealVector x);  }### Answer:
@Test public void testNull1DMatrix() { assertThatIllegalArgumentException() .isThrownBy(() -> CommonsMathWrapper.wrap((DoubleArray) null)); }
@Test public void testNullMatrix() { assertThatIllegalArgumentException() .isThrownBy(() -> CommonsMathWrapper.wrap((DoubleMatrix) null)); }