Skip to content

Commit

Permalink
TEST: tests added
Browse files Browse the repository at this point in the history
  • Loading branch information
egorklementev committed Feb 28, 2022
1 parent 0efbaa9 commit 9cbdd69
Show file tree
Hide file tree
Showing 12 changed files with 102 additions and 10 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
public class SimpleFor {
public class NestedFor {
public static void main(String[] args) {
for (int i = 0; i < 10; i++) {
for (int j = 0; j < 10; j++) {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
public class SimpleBlock {

public static void main(String[] args) {
label:
{
other_label:
{
System.out.println("passed");
}
}
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
public class NestedBlock {

public static void main(String[] args) {
{
{
System.out.println("passed");
}
}
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
public class NestedParenExpression {
public static void main(String[] args) {
int a = (1 + 2 * (8 - 5));
System.out.println(a);
System.out.println("passed");
}
}

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
public class SimpleParenExpression {
public static void main(String[] args) {
int a = (1 + 2);
System.out.println(a);
System.out.println("passed");
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
public class PrivateFinalMethod {

public static void main(String[] args) {
OuterClass obj = new OuterClass();
obj.method();
System.out.println("passed");
}
}

class OuterClass {
private final void method () {}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
public class ProtectedFinalMethod {

public static void main(String[] args) {
OuterClass obj = new OuterClass();
obj.method();
System.out.println("passed");
}
}

class OuterClass {
protected final void method () {}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
public class PublicFinalMethod {

public static void main(String[] args) {
OuterClass obj = new OuterClass();
obj.method();
System.out.println("passed");
}
}

class OuterClass {
public final void method () {}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
public class PrivateStrictFPMethod {

private static strictfp void method() {}

public static void main(String[] args) {
method();
System.out.println("passed");
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
public class ProtectedStrictFPMethod {

protected static strictfp void method() {}

public static void main(String[] args) {
method();
System.out.println("passed");
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
public class PublicStrictFPMethod {

public static strictfp void method() {}

public static void main(String[] args) {
method();
System.out.println("passed");
}
}

0 comments on commit 9cbdd69

Please sign in to comment.