diff --git a/work2_git/pom.xml b/work2_git/pom.xml new file mode 100644 index 0000000000000000000000000000000000000000..efc6304f576687d9fb2886f4fef9ad72da9d097e --- /dev/null +++ b/work2_git/pom.xml @@ -0,0 +1,34 @@ + + + 4.0.0 + + org.example + work2_git + 1.0-SNAPSHOT + + + 8 + 8 + UTF-8 + + + + + + junit + junit + 4.12 + + + org.testng + testng + RELEASE + compile + + + + + + \ No newline at end of file diff --git a/work2_git/src/main/java/org/example/Main.java b/work2_git/src/main/java/org/example/Main.java new file mode 100644 index 0000000000000000000000000000000000000000..3cb4b3e38cc996384ec5569d97bc82ef3b2381b3 --- /dev/null +++ b/work2_git/src/main/java/org/example/Main.java @@ -0,0 +1,34 @@ +package org.example; +import org.junit.Test; +import static org.junit.Assert.*; + +public class Main { +// + @Test + public void testAddition() { + // Arrange + int a = 5; + int b = 10; + + // Act + int result = a + b; + + // Assert + assertEquals(15, result); + } + + @Test + public void testSubtraction() { + // Arrange + int a = 10; + int b = 5; + + // Act + int result = a - b; + + // Assert + assertEquals(5, result); + } + + // Add more test methods as needed +} \ No newline at end of file