Skip to content

Commit 00d63d9

Browse files
committed
docs: use latest structure
1 parent aa0bef3 commit 00d63d9

8 files changed

Lines changed: 336 additions & 7 deletions

File tree

README.md

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,7 @@
33
![build status](https://github.com/praisetompane/java/actions/workflows/java.yaml/badge.svg) <br>
44

55
## Objectives
6-
- An in-depth study of:
7-
- Java's Compiler.
8-
- Java's language design, implementation and ecosystem.
6+
- Notes: The Java Programming Language
97

108
## Language Details
119
- [language specification](https://docs.oracle.com/javase/specs/)
@@ -29,9 +27,6 @@
2927
- [developer contribution guide]()
3028
- history:
3129

32-
## Testing
33-
- [JUnit](https://junit.org/junit5/)
34-
3530
## Use Cases
3631
- [Applications of Java]()
3732

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"name": "simple_test_framework",
3+
"image": "mcr.microsoft.com/devcontainers/java",
4+
"customizations": {
5+
"vscode": {
6+
"extensions": [
7+
"vscjava.vscode-gradle"
8+
],
9+
"settings": {}
10+
}
11+
},
12+
"workspaceMount": "source=${localWorkspaceFolder},target=/simple_test_framework,type=bind,consistency=delegated",
13+
"workspaceFolder": "/simple_test_framework",
14+
"runArgs": []
15+
}

applications/simple_test_framework/gradlew

Lines changed: 169 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

applications/simple_test_framework/gradlew.bat

Lines changed: 84 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
package com.xsolve.test.core;
2+
3+
import java.lang.annotation.ElementType;
4+
import java.lang.annotation.Retention;
5+
import java.lang.annotation.RetentionPolicy;
6+
import java.lang.annotation.Target;
7+
8+
//@interface tells Java this is a custom annotation
9+
@Retention(RetentionPolicy.RUNTIME)
10+
@Target(ElementType.METHOD) //method level only annoation
11+
public @interface Test {
12+
//shoudl ignore this test?
13+
public boolean enabled() default true;
14+
}
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
package com.xsolve.test.core;
2+
3+
import java.lang.annotation.ElementType;
4+
import java.lang.annotation.Retention;
5+
import java.lang.annotation.RetentionPolicy;
6+
import java.lang.annotation.Target;
7+
8+
9+
public @interface TesterInfo{
10+
public enum Priority {
11+
LOW, MEDIUM, HIGH
12+
}
13+
14+
Priority priority() default Priority.MEDIUM;
15+
16+
String[] tags() default "";
17+
18+
String createdBy() default "xsolve";
19+
20+
String lastModified() default "1992/May/02";
21+
}
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
package com.xsolve.test;
2+
3+
import com.xsolve.test.core.Test;
4+
import com.xsolve.test.core.TesterInfo;
5+
6+
/**
7+
* Created by vagrant on 2017/09/03.
8+
*/
9+
10+
@TesterInfo(priority = TesterInfo.Priority.HIGH, createdBy = "praise", tags = { "sales", "test" })
11+
public class TestClass {
12+
13+
@Test
14+
void testA() {
15+
if (true)
16+
throw new RuntimeException("This test always fails");
17+
}
18+
19+
@Test(enabled = false)
20+
void testB() {
21+
if (false)
22+
throw new RuntimeException("This test always passes");
23+
}
24+
25+
@Test
26+
void testC() {
27+
if (10 > 1) {
28+
// do nothing, this test always passes
29+
}
30+
}
31+
}

setup.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ echo "installing java"
88
asdf install java $VERSION
99
echo "done"
1010

11-
echo "set latest version to system wide version"
11+
echo "set version"
1212
asdf set java $VERSION
1313
echo "done"
1414

0 commit comments

Comments
 (0)