Skip to content

Commit d150bb2

Browse files
committed
clean the code
1 parent 414200e commit d150bb2

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

src/test/java/com/thealgorithms/matrix/MatrixMultiplicationTest.java

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,15 @@ void testMultiply3by2and2by1() {
3232
@Test
3333
void testNullMatrixA() {
3434
double[][] b = {{1, 2}, {3, 4}};
35-
assertThrows(IllegalArgumentException.class, () -> MatrixMultiplication.multiply(null, b));
35+
assertThrows(IllegalArgumentException.class,
36+
() -> MatrixMultiplication.multiply(null, b));
3637
}
3738

3839
@Test
3940
void testNullMatrixB() {
4041
double[][] a = {{1, 2}, {3, 4}};
41-
assertThrows(IllegalArgumentException.class, () -> MatrixMultiplication.multiply(a, null));
42+
assertThrows(IllegalArgumentException.class,
43+
() -> MatrixMultiplication.multiply(a, null));
4244
}
4345

4446
@Test
@@ -59,14 +61,16 @@ void testMultiplyNull() {
5961
void testIncompatibleDimensions() {
6062
double[][] a = {{1.0, 2.0}};
6163
double[][] b = {{1.0, 2.0}};
62-
assertThrows(IllegalArgumentException.class, () -> MatrixMultiplication.multiply(a, b));
64+
assertThrows(IllegalArgumentException.class,
65+
() -> MatrixMultiplication.multiply(a, b));
6366
}
6467

6568
@Test
6669
void testEmptyMatrices() {
6770
double[][] a = new double[0][0];
6871
double[][] b = new double[0][0];
69-
assertThrows(IllegalArgumentException.class, () -> MatrixMultiplication.multiply(a, b));
72+
assertThrows(IllegalArgumentException.class,
73+
() -> MatrixMultiplication.multiply(a, b));
7074
}
7175

7276
private void assertMatrixEquals(double[][] expected, double[][] actual) {

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy