Skip to content

Commit 3c7748e

Browse files
committed
Improve format in Complex tests
1 parent faa841f commit 3c7748e

2 files changed

Lines changed: 20 additions & 18 deletions

File tree

tema1_2_ejer4/src/test/java/es/codeurjc/test/complex/ComplexAbsTest.java

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,16 @@ public void absoluteTest(Complex complex, double result) {
1919
}
2020

2121
public static Collection<Object[]> values() {
22-
Object[][] data = {
23-
{ new Complex(0,0),0 },
24-
{ new Complex(1,1),1.41421},
25-
{ new Complex(2,2),2.82843},
26-
{ new Complex(5,5),7.07107},
27-
{ new Complex(10,10),14.1421},
28-
{ new Complex(10,1),10.0498},
29-
{ new Complex(20,2),20.099}
30-
};
22+
23+
Object[][] data = {
24+
{ new Complex(0,0) ,0 },
25+
{ new Complex(1,1) ,1.41421 },
26+
{ new Complex(2,2) ,2.82843 },
27+
{ new Complex(5,5) ,7.07107 },
28+
{ new Complex(10,10),14.1421 },
29+
{ new Complex(10,1) ,10.0498 },
30+
{ new Complex(20,2) ,20.099 }
31+
};
3132

3233
return Arrays.asList(data);
3334
}

tema1_2_ejer5/src/test/java/es/codeurjc/test/complex/ComplexAbsTest.java

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,16 @@ public void absoluteTest(Complex complex, double result) {
1717
}
1818

1919
public static Collection<Object[]> values() {
20-
Object[][] data = {
21-
{ new Complex(0,0),0 },
22-
{ new Complex(1,1),1.41421},
23-
{ new Complex(2,2),2.82843},
24-
{ new Complex(5,5),7.07107},
25-
{ new Complex(10,10),14.1421},
26-
{ new Complex(10,1),10.0498},
27-
{ new Complex(20,2),20.099}
28-
};
20+
21+
Object[][] data = {
22+
{ new Complex(0,0) ,0 },
23+
{ new Complex(1,1) ,1.41421 },
24+
{ new Complex(2,2) ,2.82843 },
25+
{ new Complex(5,5) ,7.07107 },
26+
{ new Complex(10,10),14.1421 },
27+
{ new Complex(10,1) ,10.0498 },
28+
{ new Complex(20,2) ,20.099 }
29+
};
2930

3031
return Arrays.asList(data);
3132
}

0 commit comments

Comments
 (0)