Skip to content
This repository was archived by the owner on Mar 12, 2024. It is now read-only.

Commit 85d5697

Browse files
committed
Changed output from cpp code, add examples tests JUnit
1 parent b97e8bd commit 85d5697

6 files changed

Lines changed: 15843 additions & 7 deletions

File tree

.classpath

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,6 @@
22
<classpath>
33
<classpathentry kind="src" path="Introspective/src"/>
44
<classpathentry exported="true" kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
5+
<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/4"/>
56
<classpathentry kind="output" path="bin"/>
67
</classpath>

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
11
/bin/
2+
3+
enviar/
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
package testsAdd;
2+
3+
import org.junit.Assert;
4+
import org.junit.Before;
5+
import org.junit.Test;
6+
7+
/*
8+
* Simple Class test sample
9+
*/
10+
public class AddTest {
11+
Math math;
12+
13+
@Before
14+
public void setUp() throws Exception {
15+
math = new Math(5, 5);
16+
}
17+
18+
@Test
19+
public void testAdd() {
20+
Assert.assertEquals(10, math.soma());
21+
}
22+
23+
}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
package testsAdd;
2+
3+
public class Math {
4+
private Integer a;
5+
private Integer b;
6+
7+
public Math(int first, int second) {
8+
a = new Integer(first);
9+
b = new Integer(second);
10+
}
11+
12+
public int soma() {
13+
return a + b;
14+
}
15+
}

0 commit comments

Comments
 (0)